Package gnu.expr
Class CheckedTarget
java.lang.Object
gnu.expr.Target
gnu.expr.StackTarget
gnu.expr.CheckedTarget
Same as StackTarget, but catch ClassCastException.
Generate code so that if coercion fails, catch ClassCastException,
and re-throw a WrongType. This gives better error messages.
-
Field Summary
Fields inherited from class gnu.expr.StackTarget
autoTruncatesFields inherited from class gnu.expr.Target
Ignore, pushObject -
Constructor Summary
ConstructorsConstructorDescriptionCheckedTarget(Type type) CheckedTarget(Type type, LambdaExp proc, int argno) CheckedTarget(Type type, String procname, int argno) -
Method Summary
Modifier and TypeMethodDescriptionprotected voiddoCoerce(Compilation comp) static voidemitCheckedCoerce(Compilation comp, LambdaExp proc, int argno, Type stackType, Type type, Variable argValue) static voidemitCheckedCoerce(Compilation comp, String procname, int argno, Type type) protected StackTargetgetClonedInstance(Type type) static TargetgetInstance(Type type) static TargetgetInstance(Type type, LambdaExp proc, int argno) static TargetgetInstance(Type type, String procname, int argno) static TargetgetInstance(Declaration decl) Methods inherited from class gnu.expr.StackTarget
compileFromStack, compileFromStack0, convert, emitCoerceFromObject, forceLazy, forceLazyIfNeeded, getTruncatingInstance, getType
-
Constructor Details
-
CheckedTarget
-
CheckedTarget
-
CheckedTarget
-
-
Method Details
-
getInstance
-
getInstance
-
getInstance
-
getInstance
-
getClonedInstance
- Overrides:
getClonedInstancein classStackTarget
-
doCoerce
- Overrides:
doCoercein classStackTarget
-
emitCheckedCoerce
-
emitCheckedCoerce
public static void emitCheckedCoerce(Compilation comp, LambdaExp proc, int argno, Type stackType, Type type, Variable argValue)
-