MCPcopy Index your code
hub / github.com/di-sukharev/opencommit / collectASequenceOfCodePointsFast

Function collectASequenceOfCodePointsFast

out/cli.cjs:51512–51521  ·  view source on GitHub ↗
(char, input, position)

Source from the content-addressed store, hash-verified

51510 function collectASequenceOfCodePoints(condition, input, position) {
51511 let result = "";
51512 while (position.position < input.length && condition(input[position.position])) {
51513 result += input[position.position];
51514 position.position++;
51515 }
51516 return result;
51517 }
51518 function collectASequenceOfCodePointsFast(char, input, position) {
51519 const idx = input.indexOf(char, position.position);
51520 const start = position.position;
51521 if (idx === -1) {
51522 position.position = input.length;
51523 return input.slice(start);
51524 }

Callers 4

dataURLProcessorFunction · 0.85
parseMIMETypeFunction · 0.85
parseSetCookieFunction · 0.85
parseUnparsedAttributesFunction · 0.85

Calls 1

sliceMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…