type Lex

bend-kube-runtime@0.2.0.0 · src/json.bend:39

import bend-kube-runtime@0.2.0.0/src/json.bend as Json
import Base

39# What the automaton expects next.
40#   LVal: a value; open says a ']' may close an empty array here
41#   LAfter: ',' or a closer, after a value
42#   LKey: a member key; open says a '}' may close an empty object
43#   LColon: the ':' after a key
44#   LStr: inside a string, reversed; esc is 0, 1 after '\', 2..5 in \uXXXX
45#   LNum, LLit: inside a number or a literal, reversed
46type Lex is Data:
47  LVal{open: Bool}
48  LAfter{}
49  LKey{open: Bool}
50  LColon{}
51  LStr{buf: String, key: Bool, esc: U32, code: U32}
52  LNum{buf: String}
53  LLit{buf: String}
54  LDone{value: Json}
55  LErr{msg: String}

Uses (4)

Used by (22)