MCPcopy Create free account
hub / github.com/Macuyiko/minecraft-python / wrapRegexp

Function wrapRegexp

ServerEditorWeb/ace/ext-language_tools.js:461–466  ·  view source on GitHub ↗
(src)

Source from the content-addressed store, hash-verified

459 snippets = [];
460
461 function wrapRegexp(src) {
462 if (src && !/^\^?\(.*\)\$?$|^\\b$/.test(src))
463 src = "(?:" + src + ")";
464
465 return src || "";
466 }
467 function guardedRegexp(re, guard, opening) {
468 re = wrapRegexp(re);
469 guard = wrapRegexp(guard);

Callers 1

guardedRegexpFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected