Package gw.internal.gosu.parser
Class ContextInferenceManager
- java.lang.Object
-
- gw.internal.gosu.parser.ContextInferenceManager
-
public class ContextInferenceManager extends Object
-
-
Constructor Summary
Constructors Constructor Description ContextInferenceManager()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
cancelInferences(Expression assignmentRoot, Expression rhs)
void
clear()
ContextInferenceManager
copy()
static Expression
getUnwrappedExpression(Expression expression)
If the expression is wrapped in ImplicitTypeAsExpressions, this will will unwrap them back down to the original expression.IType
infer(Expression e)
void
popCtx(boolean preserveInference)
void
popLoopCompromised()
void
pushCtx()
void
pushLastCtx()
void
pushLoopCompromised()
void
restoreLastCtx()
void
resumeRefCollection()
void
suspendRefCollection()
static IParsedElement
unwrapImplicitTypeAs(Expression expression)
void
updateType(Expression expression, IType typeIsType)
-
-
-
Method Detail
-
copy
public ContextInferenceManager copy()
-
pushCtx
public void pushCtx()
-
popCtx
public void popCtx(boolean preserveInference)
-
pushLastCtx
public void pushLastCtx()
-
restoreLastCtx
public void restoreLastCtx()
-
clear
public void clear()
-
updateType
public void updateType(Expression expression, IType typeIsType)
-
infer
public IType infer(Expression e)
-
cancelInferences
public void cancelInferences(Expression assignmentRoot, Expression rhs)
-
unwrapImplicitTypeAs
public static IParsedElement unwrapImplicitTypeAs(Expression expression)
-
getUnwrappedExpression
public static Expression getUnwrappedExpression(Expression expression)
If the expression is wrapped in ImplicitTypeAsExpressions, this will will unwrap them back down to the original expression.- Parameters:
expression
-- Returns:
-
pushLoopCompromised
public void pushLoopCompromised()
-
popLoopCompromised
public void popLoopCompromised()
-
suspendRefCollection
public void suspendRefCollection()
-
resumeRefCollection
public void resumeRefCollection()
-
-