Package gw.internal.gosu.ir.transform
Class GosuFragmentTransformationContext
java.lang.Object
gw.internal.gosu.ir.transform.TransformationContextBase
gw.internal.gosu.ir.transform.GosuFragmentTransformationContext
- All Implemented Interfaces:
TopLevelTransformationContext
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionGosuFragmentTransformationContext
(GosuFragment fragment, IRType compilingType, String sourceFile, boolean instrument) -
Method Summary
Modifier and TypeMethodDescriptionvoid
getSourceLine
(int lineNumber) void
initCapturedSymbolFields
(List<IRStatement> statements) void
initializeInstanceFields
(List<IRStatement> statements) void
initTypeVarFields
(List<IRStatement> statements) boolean
isExternalSymbol
(String name) boolean
boolean
isIllegalProtectedCall
(IType declaringClass, IRType root, IRelativeTypeInfo.Accessibility accessibility) void
maybeAssignOuterRef
(List<IRStatement> statements) void
maybePushSupersEnclosingThisRef
(List<IRExpression> arguments) void
pushEnumNameAndOrdinal
(IType type, List<IRExpression> args) boolean
shouldUseReflection
(IType declaringClass, IRType root, IRelativeTypeInfo.Accessibility accessibility) Methods inherited from class gw.internal.gosu.ir.transform.TransformationContextBase
compile, compileInitializerAssignment, compilingBlock, compilingEnhancement, compilingEnum, compilingProgram, createSymbol, currentlyCompilingBlock, getCurrentFunction, getCurrentFunctionName, getEnclosingType, getGosuClass, getIrClass, getScopes, getSuperType, getSymbol, getTypeParamIndex, hasSuperBeenInvoked, hasSymbol, incrementLazyTypeMethodCount, initBodyContext, initBodyContext, isBlockInvoke, isCurrentFunctionStatic, isNonStaticInnerClass, isStatic, makeAndIndexTempSymbol, makeAndIndexTempSymbol, makeTempSymbolName, markInvokingSuper, markSuperInvoked, popScope, pushScope, putSymbol, putSymbols, setIrClass, updateSuperInvokedAfterLastExpressionCompiles
-
Field Details
-
_fragment
-
_compilingType
-
_sourceFile
-
-
Constructor Details
-
GosuFragmentTransformationContext
public GosuFragmentTransformationContext(GosuFragment fragment, IRType compilingType, String sourceFile, boolean instrument)
-
-
Method Details
-
maybeAssignOuterRef
-
maybePushSupersEnclosingThisRef
-
pushEnumNameAndOrdinal
-
initCapturedSymbolFields
-
initTypeVarFields
-
initializeInstanceFields
-
getOuterThisFieldName
-
getOuterThisParamName
-
getSourceFileRef
-
getSourceLine
-
getIRTypeForCurrentClass
-
shouldUseReflection
public boolean shouldUseReflection(IType declaringClass, IRType root, IRelativeTypeInfo.Accessibility accessibility) -
isIllegalProtectedCall
public boolean isIllegalProtectedCall(IType declaringClass, IRType root, IRelativeTypeInfo.Accessibility accessibility) -
isExternalSymbol
-
isFragmentEvaluation
public boolean isFragmentEvaluation() -
addAssertionsStaticField
public void addAssertionsStaticField() -
getCurrentFunctionReturnType
- Specified by:
getCurrentFunctionReturnType
in interfaceTopLevelTransformationContext
- Overrides:
getCurrentFunctionReturnType
in classTransformationContextBase
-