public isLiteral() as Boolean
Returns true when this token belongs to a string, character, regex, numeric, or constant literal.
true
true for literal token kinds.
import klyn.code assert TokenKind.STRING.isLiteral() assert TokenKind.NUMBER.isLiteral()