public abstract class JSToStringOrNumberNode extends JavaScriptBaseNode
JSToPrimitiveNode to either a string or a numeric
value. This node is intended to be used only by comparison operators.| Constructor and Description |
|---|
JSToStringOrNumberNode() |
| Modifier and Type | Method and Description |
|---|---|
static JSToStringOrNumberNode |
create() |
protected static BigInt |
doBigInt(BigInt value) |
protected static int |
doBoolean(boolean value) |
protected static double |
doDouble(double value) |
protected static int |
doInteger(int value) |
protected static double |
doJSObject(JSObject value,
JSToDoubleNode toDoubleNode) |
protected static BigInt |
doLong(long value)
Treat long values as BigInt for comparison purposes.
|
protected static int |
doNull(Object value) |
protected static SafeInteger |
doSafeInteger(SafeInteger value) |
protected static com.oracle.truffle.api.strings.TruffleString |
doString(com.oracle.truffle.api.strings.TruffleString value) |
protected Object |
doSymbol(Symbol value) |
protected static double |
doUndefined(Object value) |
abstract Object |
execute(Object operand) |
copy, getLanguage, getRealm, hasOverloadedOperators, onReplaceaccept, adoptChildren, atomic, atomic, deepCopy, getChildren, getCost, getDebugProperties, getDescription, getEncapsulatingSourceSection, getLock, getParent, getRootNode, getSourceSection, insert, insert, isAdoptable, isSafelyReplaceableBy, notifyInserted, replace, replace, reportPolymorphicSpecialize, toStringpublic static JSToStringOrNumberNode create()
protected static int doInteger(int value)
protected static SafeInteger doSafeInteger(SafeInteger value)
protected static int doBoolean(boolean value)
protected static double doDouble(double value)
protected static com.oracle.truffle.api.strings.TruffleString doString(com.oracle.truffle.api.strings.TruffleString value)
protected static double doJSObject(JSObject value, JSToDoubleNode toDoubleNode)
protected static int doNull(Object value)
protected static double doUndefined(Object value)
protected static BigInt doLong(long value)