MCPcopy Create free account
hub / github.com/Paxa/postbird / maybeoperatorNoComma

Function maybeoperatorNoComma

public/codemirror/javascript/javascript.js:422–436  ·  view source on GitHub ↗
(type, value, noComma)

Source from the content-addressed store, hash-verified

420 return maybeoperatorNoComma(type, value, false);
421 }
422 function maybeoperatorNoComma(type, value, noComma) {
423 var me = noComma == false ? maybeoperatorComma : maybeoperatorNoComma;
424 var expr = noComma == false ? expression : expressionNoComma;
425 if (type == "=>") return cont(pushcontext, noComma ? arrowBodyNoComma : arrowBody, popcontext);
426 if (type == "operator") {
427 if (/\+\+|--/.test(value)) return cont(me);
428 if (value == "?") return cont(expression, expect(":"), expr);
429 return cont(expr);
430 }
431 if (type == "quasi") { return pass(quasi, me); }
432 if (type == ";") return;
433 if (type == "(") return contCommasep(expressionNoComma, ")", "call", me);
434 if (type == ".") return cont(property, me);
435 if (type == "[") return cont(pushlex("]"), maybeexpression, expect("]"), poplex, me);
436 }
437 function quasi(type, value) {
438 if (type != "quasi") return pass();
439 if (value.slice(value.length - 2) != "${") return cont(quasi);

Callers 1

maybeoperatorCommaFunction · 0.85

Calls 5

contFunction · 0.85
expectFunction · 0.85
passFunction · 0.85
contCommasepFunction · 0.85
pushlexFunction · 0.85

Tested by

no test coverage detected