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

Function relation

lib/web/jshint.js:20149–20179  ·  view source on GitHub ↗
(s, f)

Source from the content-addressed store, hash-verified

20147 }
20148
20149 function relation(s, f) {
20150 var x = symbol(s, 100);
20151
20152 x.infix = true;
20153 x.led = function(left) {
20154 nobreaknonadjacent(state.tokens.prev, state.tokens.curr);
20155 this.left = left;
20156 var right = this.right = expression(100);
20157
20158 if (isIdentifier(left, "NaN") || isIdentifier(right, "NaN")) {
20159 warning("W019", this);
20160 } else if (f) {
20161 f.apply(this, [left, right]);
20162 }
20163
20164 if (!left || !right) {
20165 quit("E041", state.tokens.curr);
20166 }
20167
20168 if (left.id === "!") {
20169 warning("W018", left, "!");
20170 }
20171
20172 if (right.id === "!") {
20173 warning("W018", right, "!");
20174 }
20175
20176 return this;
20177 };
20178 return x;
20179 }
20180
20181 var typeofValues = {};
20182 typeofValues.legacy = [

Callers 1

jshint.jsFile · 0.85

Calls 7

symbolFunction · 0.85
nobreaknonadjacentFunction · 0.85
isIdentifierFunction · 0.85
warningFunction · 0.85
expressionFunction · 0.70
quitFunction · 0.70
applyMethod · 0.65

Tested by

no test coverage detected