43 #include "as_config.h" 45 #ifndef AS_NO_COMPILER 47 #include "as_builder.h" 48 #include "as_scriptfunction.h" 49 #include "as_variablescope.h" 50 #include "as_bytecode.h" 51 #include "as_memory.h" 52 #include "as_datatype.h" 63 void SetVariable(
const asCDataType &dataType,
int stackOffset,
bool isTemporary);
64 void SetConstantB(
const asCDataType &dataType, asBYTE value);
65 void SetConstantQW(
const asCDataType &dataType, asQWORD value);
66 void SetConstantDW(
const asCDataType &dataType, asDWORD value);
67 void SetConstantW(
const asCDataType &dataType, asWORD value);
68 void SetConstantF(
const asCDataType &dataType,
float value);
69 void SetConstantD(
const asCDataType &dataType,
double value);
70 void SetConstantB(asBYTE value);
71 void SetConstantW(asWORD value);
72 void SetConstantQW(asQWORD value);
73 void SetConstantDW(asDWORD value);
74 void SetConstantF(
float value);
75 void SetConstantD(
double value);
76 asBYTE GetConstantB();
77 asWORD GetConstantW();
78 asQWORD GetConstantQW();
79 asDWORD GetConstantDW();
81 double GetConstantD();
83 void SetConstantData(
const asCDataType &dataType, asQWORD value);
84 asQWORD GetConstantData();
86 void SetNullConstant();
91 bool IsUndefinedFuncHandle()
const;
92 bool IsNullConstant()
const;
100 bool isExplicitHandle : 1;
101 bool isRefToLocal : 1;
144 bool IsClassMethod()
const;
145 bool IsGlobalFunc()
const;
147 bool IsLambda()
const;
148 void SetVoidExpression();
149 bool IsVoidExpression()
const;
153 bool IsAnonymousInitList()
const;
160 bool property_handle;
162 bool isVoidExpression;
173 bool isAnonymousInitList;
191 asIC_EXPLICIT_REF_CAST,
192 asIC_EXPLICIT_VAL_CAST
198 asCC_ENUM_SAME_SIZE_CONV = 2,
199 asCC_ENUM_DIFF_SIZE_CONV = 3,
200 asCC_PRIMITIVE_SIZE_CONV = 4,
201 asCC_SIGNED_CONV = 5,
202 asCC_INT_FLOAT_CONV = 6,
204 asCC_OBJ_TO_PRIMITIVE_CONV = 8,
205 asCC_TO_OBJECT_CONV = 9,
206 asCC_VARIABLE_CONV = 10
265 int CallDefaultConstructor(
const asCDataType &type,
int offset,
bool isObjectOnHeap,
asCByteCode *bc,
asCScriptNode *node,
int isVarGlobOrMem = 0,
bool derefDest =
false);
272 void CompileMemberInitialization(
asCByteCode *bc,
bool onlyDefaults);
305 void FilterConst(
asCArray<int> &funcs,
bool removeConst =
true);
344 asUINT ImplicitConvPrimitiveToObject(
asCExprContext *ctx,
const asCDataType &to,
asCScriptNode *node, EImplicitConv convType,
bool generateCode =
true,
bool allowObjectConstruct =
true);
361 void AddVariableScope(
bool isBreakScope =
false,
bool isContinueScope =
false);
362 void RemoveVariableScope();
363 void FinalizeFunction();
367 bool hasCompileErrors;
378 bool m_isConstructor;
379 bool m_isConstructorCalled;
386 int AllocateVariable(
const asCDataType &type,
bool isTemporary,
bool forceOnHeap =
false,
bool asReference =
false);
388 int GetVariableOffset(
int varIndex);
389 int GetVariableSlot(
int varOffset);
390 void DeallocateVariable(
int pos);
392 void ReleaseTemporaryVariable(
int offset,
asCByteCode *bc);
393 bool IsVariableOnHeap(
int offset);
423 bool isCompilingDefaultArg;
424 bool isProcessingDeferredParams;
430 #endif // AS_NO_COMPILER Definition: as_compiler.h:59
Definition: as_builder.h:140
Definition: as_compiler.h:176
Definition: as_scriptcode.h:48
Definition: as_bytecode.h:59
Definition: as_scriptfunction.h:146
Definition: as_compiler.h:123
Definition: as_objecttype.h:100
Definition: as_namespace.h:39
Definition: as_compiler.h:140
Definition: as_compiler.h:209
Definition: as_scriptfunction.h:74
Definition: as_builder.h:103
Definition: as_datatype.h:60
Definition: as_variablescope.h:62
Definition: as_builder.h:71
Definition: as_scriptengine.h:64
Definition: as_scriptnode.h:104
Definition: as_string.h:41
Definition: as_compiler.h:183