MCPcopy Create free account
hub / github.com/EmmyLua/EmmyLuaDebugger / end_capture

Function end_capture

third-party/lua-5.2.4/src/lstrlib.c:388–396  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

386
387
388static const char *end_capture (MatchState *ms, const char *s,
389 const char *p) {
390 int l = capture_to_close(ms);
391 const char *res;
392 ms->capture[l].len = s - ms->capture[l].init; /* close capture */
393 if ((res = match(ms, s, p)) == NULL) /* match failed? */
394 ms->capture[l].len = CAP_UNFINISHED; /* undo capture */
395 return res;
396}
397
398
399static const char *match_capture (MatchState *ms, const char *s, int l) {

Callers 1

matchFunction · 0.70

Calls 2

capture_to_closeFunction · 0.70
matchFunction · 0.70

Tested by

no test coverage detected