Package gw.internal.gosu.ir.transform
Class AbstractElementTransformer<T extends IParsedElement>
java.lang.Object
gw.internal.gosu.ir.transform.AbstractElementTransformer<T>
- Direct Known Subclasses:
AbstractExpressionTransformer,AbstractStatementTransformer,CollectionInitializerExpressionTransformer,FunctionStatementTransformer,GosuClassTransformer,GosuFragmentTransformer,MapInitializerExpressionTransformer,ObjectInitializerExpressionTransformer
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate TopLevelTransformationContextprivate static LocklessLazyVar<Boolean>private Tstatic final Stringstatic final Stringstatic final Stringstatic final Map<String,ICustomExpressionRuntime> static final Class[]static final Stringstatic final Stringstatic final Stringstatic final org.objectweb.asm.Typestatic final Stringstatic final String -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription_cc()protected voidassignStructuralTypeOwner(IExpression rootExpr, IRExpression irMethodCall) protected booleanavoidVerifyError(IType owner, IRType rootType, IRelativeTypeInfo.Accessibility accessibility) protected IRExpressionbooleanLiteral(boolean value) boxValue(IRType lhsType, IRExpression root) boxValue(IType lhsType, IRExpression root) boxValueToType(IType toType, IRExpression root) protected IRExpressionbuildAddition(IRExpression lhs, IRExpression rhs) protected IRExpressionbuildArithmetic(IRExpression lhs, IRExpression rhs, IRArithmeticExpression.Operation operation) protected IRExpressionbuildArrayLength(IRExpression root) protected IRExpressionbuildArrayLoad(IRExpression root, int index, IRType componentType) protected IRExpressionbuildArrayLoad(IRExpression root, IRExpression index, IRType componentType) protected IRStatementbuildArrayStore(IRExpression lhs, IRExpression index, IRExpression value, IRType componentType) protected IRAssignmentStatementbuildAssignment(IRSymbol symbol, IRExpression value) protected IRExpressionbuildCast(IRType castType, IRExpression expression) protected IRCompositeExpressionbuildComposite(IRElement... elements) protected IRCompositeExpressionbuildComposite(List<IRElement> elements) private IRCompositeExpressionprotected IREqualityExpressionbuildEquals(IRExpression lhs, IRExpression rhs) protected IRExpressionbuildFieldGet(IRType owner, String fieldName, IRType fieldType, IRExpression root) protected IRStatementbuildFieldSet(IRType owner, String fieldName, IRType fieldType, IRExpression root, IRExpression value) protected IRRelationalExpressionbuildGreaterThan(IRExpression lhs, IRExpression rhs) protected IRIfStatementbuildIf(IRExpression test, IRStatement ifStatement) protected IRIfStatementbuildIfElse(IRExpression test, IRStatement ifStatement, IRStatement elseStatement) protected IRExpressionbuildInitializedArray(IRType componentType, List<IRExpression> values) private IRCompositeExpressionprivate IRCompositeExpressionbuildLazyTypeResolverCall(IRMethodStatement method, IGenericTypeVariable[] tvs) protected IRMethodCallStatementbuildMethodCall(IRExpression methodCall) protected IRMethodCallExpressionbuildMethodCall(IRType ownersType, String name, boolean isInterface, IRType returnType, List<IRType> paramTypes, IRExpression root, List<IRExpression> args) protected IRMethodCallExpressionbuildMethodCall(Class ownersType, String name, Class returnType, Class[] paramTypes, IRExpression root, List<IRExpression> args) protected IRExpressionbuildNegation(IRExpression root) protected IRNewStatementbuildNewExpression(IRNewExpression newExpression) protected IRExpressionbuildNewExpression(IRType type, List<IRType> parameterTypes, List<IRExpression> args) protected IRExpressionbuildNewExpression(Class type, Class[] parameterTypes, List<IRExpression> args) protected IREqualityExpressionbuildNotEquals(IRExpression lhs, IRExpression rhs) protected IRExpressionbuildNullCheckTernary(IRExpression root, IRExpression ifNull, IRExpression ifNotNull) protected IRStatementprivate IRCompositeExpressionprotected IRExpressionbuildSubtraction(IRExpression lhs, IRExpression rhs) private IRCompositeExpressionprotected IRExpressionbuildTernary(IRExpression test, IRExpression trueValue, IRExpression falseValue, IRType resultType) protected IRThrowStatementbuildThrow(IRExpression exception) private IRExpressioncallMethod(IRMethod method, IRExpression root, boolean special, IType owner, List<IRExpression> actualArgs) callMethod(IRMethod method, IRExpression root, List<IRExpression> explicitArgs) callMethod(IRMethod method, IRExpression root, List<IRExpression> explicitArgs, int[] namedArgOrder) callMethod(IRMethod method, IRExpression root, List<IRExpression> explicitArgs, int[] namedArgOrder, boolean special) private IRExpressioncallMethod(IRType rootType, IRMethod method, IRExpression root, List<IRExpression> implicitArgs, List<IRExpression> explicitArgs, int[] namedArgOrder, boolean special) callMethod(IJavaClassInfo cls, String strMethod, Class[] paramTypes, IRExpression root, List<IRExpression> args) callMethod(Class cls, String strMethod, Class[] paramTypes, IRExpression root, List<IRExpression> args) private IRMethodCallExpressioncallMethodDirectly(IRMethod method, IRExpression root, boolean special, IType owner, List<IRExpression> actualArgs) private IRExpressioncallMethodReflectively(IType owner, String strMethod, IRType returnType, List<IRType> paramTypes, IRExpression root, List<IRExpression> args) callSpecialMethod(IRType rootType, IRMethod method, IRExpression root, List<IRExpression> explicitArgs) callSpecialMethod(IRType rootType, IRMethod method, IRExpression root, List<IRExpression> explicitArgs, int[] namedArgOrder) callSpecialMethod(IRType rootType, IRMethod method, IRExpression root, List<IRExpression> implicitArgs, List<IRExpression> explicitArgs, int[] namedArgOrder) callStaticMethod(Class cls, String strMethod, Class[] paramTypes, List<IRExpression> args) protected IRExpressioncastResultingTypeIfNecessary(IRType expectedType, IRType actualReturnType, IRExpression root) protected IRExpressioncharLiteral(char c) protected IRExpressioncheckCast(IType type, IRExpression expression) protected IRExpressioncheckCast(IType type, IRExpression expression, boolean bGetConcreteTypeForMetaType) protected IRExpressioncheckCast(Class cls, IRExpression expression) protected IRExpressionclassLiteral(IRType value) protected IRExpressionclassLiteral(IJavaClassInfo value) protected IRExpressionclassLiteral(Class value) Deprecated.static voidprotected IRExpressionconvertBoxedNullToPrimitive(IType boxedType) protected IRExpressionconvertNullToPrimitive(IType primitive) protected IRAssignmentStatementconvertOperandToBig(IType bigType, Class bigClass, IType operandType, IRExpression operand, IRSymbol tempRet) protected IRAssignmentStatementconvertOperandToPrimitive(IType primitiveType, IType operandType, IRExpression operand, IRSymbol tempRet) protected IRAssignmentStatementconvertOperandToRational(IType operandType, IRExpression operand, IRSymbol tempRet) private booleanequivalentTypes(IType type1, IType type2) protected static List<IRExpression>exprList(IRExpression... expressions) protected IRExpressionfastStringCoercion(IRExpression expr, IType operandType) protected final ITypefindComparableParamType(IType type) private ITypefindCompareToParamType(IType type) static ITypefindDimensionType(IType type) protected IGosuVarPropertyInfoprotected StringgetClassInfos(IType[] parameters) getConcreteType(IType type) protected IRType[]getConstructorParamTypes(IType[] declaredParams, int iTypeParams, IType type) Parameters are order like so: ctor( [OuterThis,] [This,] [CapturedSymbols,] [TypeParams,] params )static ICustomExpressionRuntimegetCustomRuntime(String id, IType enclosingClass) static FieldgetDeclaredField(Class cls, String strName) static FieldgetDeclaredFieldImpl(Class cls, String strName) static IJavaClassMethodgetDeclaredMethod(IJavaClassInfo cls, String strName, Class... params) static MethodgetDeclaredMethod(Class cls, String strName, Class... params) private static IJavaClassMethodgetDeclaredMethodImpl(IJavaClassInfo cls, String strName, Class... params) private static MethodgetDeclaredMethodImpl(Class cls, String strName, Class... params) getDefaultConstIns(IType type) static IRTypegetDescriptor(IType type) static IRTypegetDescriptor(IType type, boolean getConcreteTypeForMetaType) static IRTypestatic IRTypegetDescriptor(Class cls) static IDynamicFunctionSymbolgetEnclosingDFS(ICompilableType gsClass) protected IRExpressiongetField(IRProperty field, IRExpression root) private IRExpressiongetField(IType owner, String strField, IRType fieldType, IRelativeTypeInfo.Accessibility accessibility, IRExpression root) protected IRExpressiongetField_new(IRProperty irProp, IRExpression root, IRType expectedType) private IRExpressiongetFieldImpl_new(IRProperty irProp, IRExpression root) private IRExpressiongetFieldReflectively(IType owner, String strField, IRType fieldType, IRExpression root) private IRExpressiongetFieldReflectively_new(IRProperty irProp, IRExpression root) private IGenericTypeVariable[]getGenericFunctionTypeVariables(IDynamicFunctionSymbol currentFunction) protected IRExpressiongetInstanceField(IType owner, String strField, IRType fieldType, IRelativeTypeInfo.Accessibility accessibility, IRExpression root) getIRTypes(IJavaClassInfo[] iJavaClassInfos) getIRTypes(Class[] classes) intgetModifiers(Symbol symbol) private IModuleprotected Tstatic ITypegetRuntimeEnclosingType(IType type) private IRExpressionprotected IRExpressiongetStaticField(IType owner, String strField, IRType fieldType, IRelativeTypeInfo.Accessibility accessibility) static IType[]getTypes(IParameterInfo[] parameters) protected final StringgetTypeVarParamName(IGenericTypeVariable typeVar) static List<IGenericTypeVariable>private static IGenericTypeVariable[]protected IRExpressionhandleCustomExpressionRuntime(ICustomExpressionRuntime customRuntime, IType expectedType) handleNamedArgs(List<IRExpression> explicitArgs, int[] namedArgOrder) Facilitates evaluation of named args in lexical order.protected IRIdentifieridentifier(IRSymbol symbol) protected IRAssignmentStatementinitLocalVar(Symbol varSym, IRExpression initialValue) protected IRAssignmentStatementinitLocalVarWithDefault(Symbol varSym) static ObjectinitMultiArray(IType componentType, Object instance, int iDimension, int[] sizes) protected booleanstatic booleanstatic booleanisBoxedIntType(IType type) static booleanstatic booleanisBytecodeType(IType type) private booleanprotected booleanbooleanstatic booleanisEnhancementType(IType type) protected static booleanisEvalProgram(IGosuClassInternal gsClass) static booleanisExecuteMethod(String name) protected booleanisHandledByCustomCoercion(IType operandType) static booleanprotected ICompilableTypeInternalprotected booleanstatic booleanisNonBigBoxedNumberType(IType type) static booleanisNonStaticInnerClass(IType type) static booleanisNumberType(IType type) protected booleanisPrimitiveNumberType(IType type) booleanbooleanprivate booleanprivate booleanisRecursiveTypeParsing(IType type) private booleanstatic List<GosuAnnotationInfo>makeAnnotationInfos(List<IGosuAnnotation> gosuAnnotations, IFeatureInfo fiAnnotated) protected IRExpressionmakeArrayViaTypeInfo(IType atomicType, List<Expression> valueExpressions) private static StringmakeCustomRuntimeKey(IType enclosingClass, int iLineNum, int iColumnNum) protected IRExpressionmakeEmptyArrayViaTypeInfo(IType atomicType, List<Expression> sizeExpressions) private IRMethodStatementprivate IRMethodStatementprotected IRSymbolmakeIRSymbol(Symbol varSym) private IRMethodStatementmakeLazyTypeMethod(IType type, IGenericTypeVariable[] tvs) private IRMethodStatementprivate IRMethodStatementmakeSuperCallLazyTypeMethod(IType type, IGenericTypeVariable[] tvs) private IRExpressionmaybeGetFromEnclosingFunction(ICompilableType gsClass, TypeVariableType type, String strTypeVarField) An anonymous class enclosed in a generic function has as a synthetic field the type parameter[s] from the function.private IRExpressionmaybePushFastLazyType(IType type) maybeUnwrapMetaType(IType rootType) private static ITypemaybeUnwrapProxy(IType type) protected IRExpressionnewArray(IRType atomicType, IRExpression sizeExpression) nullCheckVar(IRSymbol symbol) protected IRExpressionprotected IRExpressionnumberConvert(IRType from, IRType to, IRExpression root) protected IRExpressionnumberConvert(IType from, IType to, IRExpression root) protected IRExpressionnumericLiteral(Number value) protected IRExpressionpushArrayOfDefValueExpr(IExpression[] array) protected IRExpressionpushArrayOfString(String[] array) pushArrayOfTypes(IType[] types) protected voidpushCapturedSymbols(IType type, List<IRExpression> args, boolean ignoreExternalSymbols) private IRExpressionpushClassLiteral(IRType value, IType type) protected IRExpressionpushConstant(Object constant) private intpushEnclosingFunctionTypeParams(IParsedElement pe, IType type, int iCount, List<IRExpression> args) private voidpushEnhancementTypeParams(IRMethod irMethod, IType enhancementType, List<IRExpression> args) protected voidprotected IRExpressionpushLazyType(IType type) pushLazyType(IType type, IGenericTypeVariable[] tvs) private IRExpressionpushLazyTypeByFqn(IType boundingType) private IRExpressionpushLazyTypeWithInvokeDynamic(IType type, IGenericTypeVariable[] tvs) protected IRExpressionpushNull()protected IRExpressionprotected IRExpressionprotected IRExpressionpushOuter(IType outerTarget, IType currentOuter, IRExpression root) protected IRExpressionpushParamTypes(IParameterInfo[] parameters) protected IRExpressionpushString(IExpression expr) protected IRExpressionpushThis()protected IRExpressionpushThisOrOuter(IType currentType) protected intpushTypeParametersForConstructor(IExpression expr, IType type, List<IRExpression> args, boolean bSuperCall, boolean genericJavaInterop) private voidpushTypeParams(IRMethod irMethod, List<IRExpression> args) static booleanstatic booleanstatic booleanprotected voidprotected IRStatementsetField(IRProperty field, IRExpression root, IRExpression value) protected IRStatementsetField(IType owner, String strField, IRType fieldType, IRelativeTypeInfo.Accessibility accessibility, IRExpression root, IRExpression value) private IRStatementsetFieldReflectively(IType owner, String strField, IRExpression root, IRExpression value) protected IRStatementsetInstanceField(IType owner, String strField, IRType fieldType, IRelativeTypeInfo.Accessibility accessibility, IRExpression root, IRExpression value) protected IRStatementsetStaticField(IType owner, String strField, IRType fieldType, IRelativeTypeInfo.Accessibility accessibility, IRExpression value) private booleanprotected IRExpressionstringLiteral(String value) unboxValueFromType(IType boxedType, IRExpression root) unboxValueToType(IRType lhsType, IRExpression expression) unboxValueToType(IType lhsType, IRExpression expression) static CharactervalueOf(char c)
-
Field Details
-
CTX_SYMBOL_SUFFIX
- See Also:
-
CTX_SYMBOL
- See Also:
-
CUSTOM_RUNTIMES
-
EMPTY_CLASS_ARRAY
-
OUTER_ACCESS
- See Also:
-
CAPTURED_VAR_PREFIX
- See Also:
-
ENHANCEMENT_TYPE_PARAM_PREFIX
- See Also:
-
TYPE_PARAM_PREFIX
- See Also:
-
ENUM_PARAM_PREFIX
- See Also:
-
OBJECT_TYPE
public static final org.objectweb.asm.Type OBJECT_TYPE -
ENHANCEMENT_THIS_REF
- See Also:
-
_cc
-
_parsedElement
-
_checkedArithmetic
-
-
Constructor Details
-
AbstractElementTransformer
-
-
Method Details
-
clearCustomRuntimes
public static void clearCustomRuntimes() -
_cc
-
setCc
-
getParsedElement
-
getGosuClass
-
callStaticMethod
public IRExpression callStaticMethod(Class cls, String strMethod, Class[] paramTypes, List<IRExpression> args) -
callMethod
public IRExpression callMethod(Class cls, String strMethod, Class[] paramTypes, IRExpression root, List<IRExpression> args) -
callMethod
public IRExpression callMethod(IJavaClassInfo cls, String strMethod, Class[] paramTypes, IRExpression root, List<IRExpression> args) -
callMethod
-
callMethod
public IRExpression callMethod(IRMethod method, IRExpression root, List<IRExpression> explicitArgs, int[] namedArgOrder) -
callMethod
public IRExpression callMethod(IRMethod method, IRExpression root, List<IRExpression> explicitArgs, int[] namedArgOrder, boolean special) -
callSpecialMethod
public IRExpression callSpecialMethod(IRType rootType, IRMethod method, IRExpression root, List<IRExpression> explicitArgs) -
callSpecialMethod
public IRExpression callSpecialMethod(IRType rootType, IRMethod method, IRExpression root, List<IRExpression> explicitArgs, int[] namedArgOrder) -
callSpecialMethod
public IRExpression callSpecialMethod(IRType rootType, IRMethod method, IRExpression root, List<IRExpression> implicitArgs, List<IRExpression> explicitArgs, int[] namedArgOrder) -
callMethod
private IRExpression callMethod(IRType rootType, IRMethod method, IRExpression root, List<IRExpression> implicitArgs, List<IRExpression> explicitArgs, int[] namedArgOrder, boolean special) -
handleNamedArgs
Facilitates evaluation of named args in lexical order. E.g.,callMe( :param3 = expr1, :param1 = expr2, :param2 = expr3 )
is parsed as:callMe( expr2, expr3, expr1 )
which is compiled to:temp1 = expr1 temp2 = expr2 temp3 = expr3 callMe( temp2, temp3, temp1 )
- Parameters:
explicitArgs- The arg expressions in proper order for the target call. The expressions are replaced with the temp vars.namedArgOrder- The lexical ordering of the args- Returns:
- The temp var assignments in lexical order
-
shouldAddExternalSymbolsMapToCall
-
isExecuteMethod
-
callMethod
private IRExpression callMethod(IRMethod method, IRExpression root, boolean special, IType owner, List<IRExpression> actualArgs) -
callMethodDirectly
private IRMethodCallExpression callMethodDirectly(IRMethod method, IRExpression root, boolean special, IType owner, List<IRExpression> actualArgs) -
isSuperCall
private boolean isSuperCall() -
pushEnhancementTypeParams
private void pushEnhancementTypeParams(IRMethod irMethod, IType enhancementType, List<IRExpression> args) -
callMethodReflectively
private IRExpression callMethodReflectively(IType owner, String strMethod, IRType returnType, List<IRType> paramTypes, IRExpression root, List<IRExpression> args) -
pushTypeParams
-
nullCheckVar
-
pushLazyType
-
pushLazyType
-
pushLazyTypeWithInvokeDynamic
-
maybePushFastLazyType
-
buildLazyTypeResolverCall
private IRCompositeExpression buildLazyTypeResolverCall(IRMethodStatement method, IGenericTypeVariable[] tvs) -
buildStaticLazyTypeResolverCall
-
buildEnhancementLazyTypeResolverCall
-
buildInstanceLazyTypeResolverCall
-
buildSuperCallLazyTypeResolverCall
private IRCompositeExpression buildSuperCallLazyTypeResolverCall(IRMethodStatement method, IGenericTypeVariable[] tvs) -
makeLazyTypeMethod
-
makeStaticLazyTypeMethod
-
makeEnhancementLazyTypeMethod
-
makeSuperCallLazyTypeMethod
-
makeInstanceLazyTypeMethod
-
getGenericFunctionTypeVariables
private IGenericTypeVariable[] getGenericFunctionTypeVariables(IDynamicFunctionSymbol currentFunction) -
pushType
-
pushType
-
isRecursiveTypeParsing
-
pushArrayOfString
-
pushArrayOfDefValueExpr
-
pushArrayOfTypes
-
requiresImplicitEnhancementArg
-
requiresImplicitEnhancementArg
-
getClassInfos
-
getModule
-
getConcreteType
-
getDescriptor
-
getDescriptor
-
getDescriptor
-
getDescriptor
-
getDefaultConstIns
-
getModifiers
-
isReadObjectOrWriteObjectMethod
-
isCompilingEnhancement
public boolean isCompilingEnhancement() -
isProgramOrEnclosedInProgram
-
boxValue
-
valueOf
-
boxValue
-
boxValueToType
-
unboxValueToType
-
unboxValueToType
-
unboxValueFromType
-
isProgram
-
isEnhancementType
-
isBytecodeType
-
isBytecodeType
-
getTypes
-
pushString
-
pushParamTypes
-
pushNull
-
pushConstant
-
convertBoxedNullToPrimitive
-
convertNullToPrimitive
-
checkCast
-
checkCast
-
checkCast
protected IRExpression checkCast(IType type, IRExpression expression, boolean bGetConcreteTypeForMetaType) -
convertOperandToBig
protected IRAssignmentStatement convertOperandToBig(IType bigType, Class bigClass, IType operandType, IRExpression operand, IRSymbol tempRet) -
convertOperandToRational
protected IRAssignmentStatement convertOperandToRational(IType operandType, IRExpression operand, IRSymbol tempRet) -
convertOperandToPrimitive
protected IRAssignmentStatement convertOperandToPrimitive(IType primitiveType, IType operandType, IRExpression operand, IRSymbol tempRet) -
numberConvert
-
numberConvert
-
isIntType
-
isPrimitiveNumberType
-
isBigType
-
isNonBigBoxedNumberType
-
isBoxedIntType
-
isNumberType
-
isMemberOnEnclosingType
-
isMemberOnEnhancementOfEnclosingType
-
maybeUnwrapProxy
-
pushThis
-
pushThisOrOuter
-
pushOuter
-
pushOuter
-
pushOuter
-
getInstanceField
protected IRExpression getInstanceField(IType owner, String strField, IRType fieldType, IRelativeTypeInfo.Accessibility accessibility, IRExpression root) -
getStaticField
protected IRExpression getStaticField(IType owner, String strField, IRType fieldType, IRelativeTypeInfo.Accessibility accessibility) -
getField
-
setField
-
setInstanceField
protected IRStatement setInstanceField(IType owner, String strField, IRType fieldType, IRelativeTypeInfo.Accessibility accessibility, IRExpression root, IRExpression value) -
setStaticField
protected IRStatement setStaticField(IType owner, String strField, IRType fieldType, IRelativeTypeInfo.Accessibility accessibility, IRExpression value) -
getField
private IRExpression getField(IType owner, String strField, IRType fieldType, IRelativeTypeInfo.Accessibility accessibility, IRExpression root) -
avoidVerifyError
protected boolean avoidVerifyError(IType owner, IRType rootType, IRelativeTypeInfo.Accessibility accessibility) -
getFieldReflectively
private IRExpression getFieldReflectively(IType owner, String strField, IRType fieldType, IRExpression root) -
setField
protected IRStatement setField(IType owner, String strField, IRType fieldType, IRelativeTypeInfo.Accessibility accessibility, IRExpression root, IRExpression value) -
setFieldReflectively
private IRStatement setFieldReflectively(IType owner, String strField, IRExpression root, IRExpression value) -
isEvalProgram
-
getDeclaredField
-
getDeclaredFieldImpl
-
getDeclaredMethod
-
getDeclaredMethod
public static IJavaClassMethod getDeclaredMethod(IJavaClassInfo cls, String strName, Class... params) -
getDeclaredMethodImpl
-
getDeclaredMethodImpl
private static IJavaClassMethod getDeclaredMethodImpl(IJavaClassInfo cls, String strName, Class... params) -
newArray
-
makeArrayViaTypeInfo
-
makeEmptyArrayViaTypeInfo
protected IRExpression makeEmptyArrayViaTypeInfo(IType atomicType, List<Expression> sizeExpressions) -
initMultiArray
-
pushRuntimeTypeOfTypeVar
-
getRuntimeTypeParameter
-
pushLazyTypeByFqn
-
equivalentTypes
-
maybeGetFromEnclosingFunction
private IRExpression maybeGetFromEnclosingFunction(ICompilableType gsClass, TypeVariableType type, String strTypeVarField) An anonymous class enclosed in a generic function has as a synthetic field the type parameter[s] from the function. -
getEnclosingDFS
-
getTypeVarsForDFS
-
getTypeVarsForEnhancement
-
getConstructorParamTypes
Parameters are order like so: ctor( [OuterThis,] [This,] [CapturedSymbols,] [TypeParams,] params ) -
pushTypeParametersForConstructor
protected int pushTypeParametersForConstructor(IExpression expr, IType type, List<IRExpression> args, boolean bSuperCall, boolean genericJavaInterop) -
pushEnumSuperConstructorArguments
-
pushEnclosingFunctionTypeParams
private int pushEnclosingFunctionTypeParams(IParsedElement pe, IType type, int iCount, List<IRExpression> args) -
initLocalVarWithDefault
-
initLocalVar
-
makeIRSymbol
-
pushCapturedSymbols
protected void pushCapturedSymbols(IType type, List<IRExpression> args, boolean ignoreExternalSymbols) -
isCapturedOnEnclosingAnonymousClass
private boolean isCapturedOnEnclosingAnonymousClass(ICapturedSymbol sym, IGosuClassInternal gsClass) -
collectArgsIntoObjArray
-
getActualPropertyInfo
-
castResultingTypeIfNecessary
protected IRExpression castResultingTypeIfNecessary(IRType expectedType, IRType actualReturnType, IRExpression root) -
getRuntimeEnclosingType
- Parameters:
type-- Returns:
- the actual runtime enclosing type of this type (handles the case of enhancements, when the "enclosing type" at runtime will be the enhanced object, rather than the acutal enclosing type)
-
maybeUnwrapMetaType
-
classLiteral
Deprecated. -
classLiteral
-
classLiteral
-
pushClassLiteral
-
getCustomRuntime
-
handleCustomExpressionRuntime
protected IRExpression handleCustomExpressionRuntime(ICustomExpressionRuntime customRuntime, IType expectedType) -
makeCustomRuntimeKey
-
pushExternalSymbolsMap
-
requiresExternalSymbolCapture
-
buildMethodCall
protected IRMethodCallExpression buildMethodCall(IRType ownersType, String name, boolean isInterface, IRType returnType, List<IRType> paramTypes, IRExpression root, List<IRExpression> args) -
buildMethodCall
protected IRMethodCallExpression buildMethodCall(Class ownersType, String name, Class returnType, Class[] paramTypes, IRExpression root, List<IRExpression> args) -
buildCast
-
numericLiteral
-
charLiteral
-
booleanLiteral
-
nullLiteral
-
stringLiteral
-
buildArrayLoad
-
buildArrayLoad
-
buildFieldGet
protected IRExpression buildFieldGet(IRType owner, String fieldName, IRType fieldType, IRExpression root) -
buildFieldSet
protected IRStatement buildFieldSet(IRType owner, String fieldName, IRType fieldType, IRExpression root, IRExpression value) -
buildAssignment
-
identifier
-
buildArrayStore
protected IRStatement buildArrayStore(IRExpression lhs, IRExpression index, IRExpression value, IRType componentType) -
buildInitializedArray
-
buildNewExpression
protected IRExpression buildNewExpression(IRType type, List<IRType> parameterTypes, List<IRExpression> args) -
buildNewExpression
protected IRExpression buildNewExpression(Class type, Class[] parameterTypes, List<IRExpression> args) -
getTypeVarParamName
-
getCapturedSymbolParameterName
-
exprList
-
getIRTypes
-
getIRTypes
-
buildNullCheckTernary
protected IRExpression buildNullCheckTernary(IRExpression root, IRExpression ifNull, IRExpression ifNotNull) -
buildThrow
-
buildIf
-
buildIfElse
protected IRIfStatement buildIfElse(IRExpression test, IRStatement ifStatement, IRStatement elseStatement) -
buildComposite
-
buildComposite
-
buildMethodCall
-
buildNewExpression
-
buildReturn
-
buildEquals
-
buildNotEquals
-
buildGreaterThan
-
buildTernary
protected IRExpression buildTernary(IRExpression test, IRExpression trueValue, IRExpression falseValue, IRType resultType) -
buildAddition
-
buildSubtraction
-
buildArithmetic
protected IRExpression buildArithmetic(IRExpression lhs, IRExpression rhs, IRArithmeticExpression.Operation operation) -
buildNegation
-
buildArrayLength
-
inStaticContext
protected boolean inStaticContext() -
makeAnnotationInfos
public static List<GosuAnnotationInfo> makeAnnotationInfos(List<IGosuAnnotation> gosuAnnotations, IFeatureInfo fiAnnotated) -
isCheckedArithmeticEnabled
protected boolean isCheckedArithmeticEnabled() -
isNonStaticInnerClass
-
getField_new
-
getFieldImpl_new
-
getFieldReflectively_new
-
assignStructuralTypeOwner
-
fastStringCoercion
-
isHandledByCustomCoercion
-
findDimensionType
-
findComparableParamType
-
findCompareToParamType
-