MCPcopy Create free account
hub / github.com/TextGeneratorio/text-generator.io / commasep

Function commasep

static/libs/javascript.js:562–580  ·  view source on GitHub ↗
(what, end, sep)

Source from the content-addressed store, hash-verified

560 if (type == "(") return pass(functiondef);
561 }
562 function commasep(what, end, sep) {
563 function proceed(type, value) {
564 if (sep ? sep.indexOf(type) > -1 : type == ",") {
565 var lex = cx.state.lexical;
566 if (lex.info == "call") lex.pos = (lex.pos || 0) + 1;
567 return cont(function(type, value) {
568 if (type == end || value == end) return pass()
569 return pass(what)
570 }, proceed);
571 }
572 if (type == end || value == end) return cont();
573 if (sep && sep.indexOf(";") > -1) return pass(what)
574 return cont(expect(end));
575 }
576 return function(type, value) {
577 if (type == end || value == end) return cont();
578 return pass(what, proceed);
579 };
580 }
581 function contCommasep(what, end, info) {
582 for (var i = 3; i < arguments.length; i++)
583 cx.cc.push(arguments[i]);

Callers 13

expressionInnerFunction · 0.85
maybeoperatorNoCommaFunction · 0.85
contCommasepFunction · 0.85
typeexprFunction · 0.85
afterTypeFunction · 0.85
maybeTypeArgsFunction · 0.85
functiondefFunction · 0.85
functiondeclFunction · 0.85
typenameFunction · 0.85
classNameAfterFunction · 0.85
afterExportFunction · 0.85
arrayLiteralFunction · 0.85

Calls 2

contFunction · 0.85
passFunction · 0.70

Tested by

no test coverage detected