MCPcopy
hub / github.com/witheve/Eve / splitBySlash

Function splitBySlash

src/codemirror.js:12950–12961  ·  view source on GitHub ↗
(argString)

Source from the content-addressed store, hash-verified

12948 }
12949 }
12950 function splitBySlash(argString) {
12951 var slashes = findUnescapedSlashes(argString) || [];
12952 if (!slashes.length) return [];
12953 var tokens = [];
12954 // in case of strings like foo/bar
12955 if (slashes[0] !== 0) return;
12956 for (var i = 0; i < slashes.length; i++) {
12957 if (typeof slashes[i] == 'number')
12958 tokens.push(argString.substring(slashes[i] + 1, slashes[i+1]));
12959 }
12960 return tokens;
12961 }
12962
12963 function findUnescapedSlashes(str) {
12964 var escapeNextChar = false;

Callers 1

VimFunction · 0.85

Calls 1

findUnescapedSlashesFunction · 0.85

Tested by

no test coverage detected