Class StringPrototypeBuiltins.JSStringCharCodeAtNode

All Implemented Interfaces:
com.oracle.truffle.api.instrumentation.InstrumentableNode, com.oracle.truffle.api.nodes.NodeInterface, JSBuiltinNode.Inlineable, Cloneable
Direct Known Subclasses:
StringPrototypeBuiltins.JSStringCharCodeAtNode.Inlined
Enclosing class:
StringPrototypeBuiltins

public abstract static class StringPrototypeBuiltins.JSStringCharCodeAtNode extends JSBuiltinNode implements JSBuiltinNode.Inlineable
Implementation of the String.prototype.charCodeAt() method as specified by ECMAScript 5.1 in 15.5.4.5.
  • Constructor Details

    • JSStringCharCodeAtNode

      public JSStringCharCodeAtNode(JSContext context, JSBuiltin builtin)
  • Method Details

    • posInBounds

      protected static boolean posInBounds(com.oracle.truffle.api.strings.TruffleString thisStr, int pos)
    • charCodeAtInBounds

      protected int charCodeAtInBounds(com.oracle.truffle.api.strings.TruffleString thisStr, int pos, com.oracle.truffle.api.strings.TruffleString.ReadCharUTF16Node readChar)
    • charCodeAtOutOfBounds

      protected double charCodeAtOutOfBounds(com.oracle.truffle.api.strings.TruffleString thisStr, int pos)
    • charCodeAtGeneric

      protected Object charCodeAtGeneric(Object thisObj, Object indexObj, com.oracle.truffle.api.strings.TruffleString.ReadCharUTF16Node readChar, JSToNumberNode toNumberNode, com.oracle.truffle.api.profiles.InlinedConditionProfile indexOutOfBounds)
    • createInlined

    • within

      protected static int within(int value, int min, int max)
    • withinNumber

      protected static int withinNumber(Number value, int min, int max)
    • requireObjectCoercible

      protected final void requireObjectCoercible(Object target)
    • toString

      protected com.oracle.truffle.api.strings.TruffleString toString(Object target)
    • toIntegerAsInt

      protected int toIntegerAsInt(Object target)