TDJaMScanner:
CEDAR
DEFINITIONS = {
ROPE: TYPE = Rope.ROPE;
Any: TYPE = REF ANY;
Token: TYPE = RECORD[type: TokenType, truncated, escaped: BOOL, start, len: INT];
TokenType: TYPE = {nil, name, string, int, real, lbrace, rbrace, comment};
nullToken: Token = [type: nil, truncated: FALSE, escaped: FALSE, start: 0, len: 0];
GetToken: PROC[reader: RopeReader.Ref] RETURNS[Token];
ParseToken: PROC[token: Token, rope: ROPE] RETURNS[Any]
}.