MCPcopy Create free account
hub / github.com/cockroachdb/cockroachdb-parser / pop

Method pop

pkg/util/json/parser.go:256–264  ·  view source on GitHub ↗

pop stack.

()

Source from the content-addressed store, hash-verified

254
255// pop stack.
256func (p *fastJSONParser) pop() {
257 top := len(p.kind) - 1
258 if p.kind[top] == kindArray {
259 p.arr = p.arr[:len(p.arr)-1]
260 } else {
261 p.obj = p.obj[:len(p.obj)-1]
262 }
263 p.kind = p.kind[:top]
264}
265
266// stackReturn returns json object to the top of the stack
267// and transitions state machine to the next state.

Callers 2

buildArrayMethod · 0.95
buildObjectMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected