MCPcopy Create free account
hub / github.com/OpenEndedGroup/Field2 / proppattern

Function proppattern

lib/web/CodeMirror/mode/javascript/javascript.js:678–688  ·  view source on GitHub ↗
(type, value)

Source from the content-addressed store, hash-verified

676 if (type == "{") return contCommasep(proppattern, "}");
677 }
678 function proppattern(type, value) {
679 if (type == "variable" && !cx.stream.match(/^\s*:/, false)) {
680 register(value);
681 return cont(maybeAssign);
682 }
683 if (type == "variable") cx.marked = "property";
684 if (type == "spread") return cont(pattern);
685 if (type == "}") return pass();
686 if (type == "[") return cont(expression, expect(']'), expect(':'), proppattern);
687 return cont(expect(":"), pattern, maybeAssign);
688 }
689 function eltpattern() {
690 return pass(pattern, maybeAssign)
691 }

Callers

nothing calls this directly

Calls 5

registerFunction · 0.70
contFunction · 0.70
passFunction · 0.70
expectFunction · 0.70
matchMethod · 0.45

Tested by

no test coverage detected