
TokenVal stores an instance of a Token at a specific Location.
Slots
- equals
-
Compare this object to the specified for equality. This method may be accessed via the == and != shortcut operators. If not overridden the default implementation compares for reference equality using the === operator. If this method is overridden, then hash() must also be overridden such that any two objects which return true for equals() must return the same value for hash().
- hash
-
override Int hash()
Return a unique hashcode for this object. If a class overrides hash() then it must ensure if equals() returns true for any two objects then they have same hash code.
- isCallOpenParen
-
Bool isCallOpenParen()
Return if this token is a left opening paren, but only if on the same line:
Ok:
call(...)
Not ok:
call (...)
- isIndexOpenBracket
-
Bool isIndexOpenBracket()
Return if this token is a left opening bracket, but only if on the same line:
Ok:
expr[...]
Not ok:
expr [...]
- kind
-
Token kind
- make
- newline
-
Bool newline
- toStr
-
override Str toStr()
Return a string representation of this object.
- val
-
Obj val