MCPcopy Create free account
hub / github.com/dataease/SQLBot / opExecute

Function opExecute

frontend/public/swagger-ui-bundle.js:43314–43482  ·  view source on GitHub ↗
(o, _)

Source from the content-addressed store, hash-verified

43312 ? i.ast.setLength($)
43313 : i.ast.up(U, Z.name, C, Y.phraseLength))))
43314 },
43315 opExecute = (o, _) => {
43316 const j = `${a}opExecute(): `,
43317 Z = w[o]
43318 switch (
43319 ((V += 1),
43320 $ > U && (U = $),
43321 ($ += 1),
43322 Y.refresh(),
43323 i.trace && i.trace.down(Z, _),
43324 Z.type)
43325 ) {
43326 case s.ALT:
43327 ;((o, i) => {
43328 const a = w[o]
43329 for (
43330 let o = 0;
43331 o < a.children.length &&
43332 (opExecute(a.children[o], i), Y.state === s.NOMATCH);
43333 o += 1
43334 );
43335 })(o, _)
43336 break
43337 case s.CAT:
43338 ;((o, a) => {
43339 let u, _, x, C
43340 const j = w[o]
43341 ;(i.ast && (_ = i.ast.getLength()), (u = !0), (x = a), (C = 0))
43342 for (let o = 0; o < j.children.length; o += 1) {
43343 if ((opExecute(j.children[o], x), Y.state === s.NOMATCH)) {
43344 u = !1
43345 break
43346 }
43347 ;((x += Y.phraseLength), (C += Y.phraseLength))
43348 }
43349 u
43350 ? ((Y.state = 0 === C ? s.EMPTY : s.MATCH), (Y.phraseLength = C))
43351 : ((Y.state = s.NOMATCH), (Y.phraseLength = 0), i.ast && i.ast.setLength(_))
43352 })(o, _)
43353 break
43354 case s.REP:
43355 ;((o, a) => {
43356 let u, _, C, j
43357 const L = w[o]
43358 if (0 === L.max) return ((Y.state = s.EMPTY), void (Y.phraseLength = 0))
43359 for (
43360 _ = a, C = 0, j = 0, i.ast && (u = i.ast.getLength());
43361 !(_ >= x.length) &&
43362 (opExecute(o + 1, _), Y.state !== s.NOMATCH) &&
43363 Y.state !== s.EMPTY &&
43364 ((j += 1), (C += Y.phraseLength), (_ += Y.phraseLength), j !== L.max);
43365 );
43366 Y.state === s.EMPTY || j >= L.min
43367 ? ((Y.state = 0 === C ? s.EMPTY : s.MATCH), (Y.phraseLength = C))
43368 : ((Y.state = s.NOMATCH), (Y.phraseLength = 0), i.ast && i.ast.setLength(u))
43369 })(o, _)
43370 break
43371 case s.RNM:

Callers 1

kpFunction · 0.85

Calls 3

opUDTFunction · 0.85
zFunction · 0.50

Tested by

no test coverage detected