MCPcopy Index your code
hub / github.com/gpujs/gpu.js / astConditionalExpression

Method astConditionalExpression

src/backend/function-node.js:979–991  ·  view source on GitHub ↗
(ast, retArr)

Source from the content-addressed store, hash-verified

977 }
978
979 astConditionalExpression(ast, retArr) {
980 if (ast.type !== 'ConditionalExpression') {
981 throw this.astErrorOutput('Not a conditional expression', ast);
982 }
983 retArr.push('(');
984 this.astGeneric(ast.test, retArr);
985 retArr.push('?');
986 this.astGeneric(ast.consequent, retArr);
987 retArr.push(':');
988 this.astGeneric(ast.alternate, retArr);
989 retArr.push(')');
990 return retArr;
991 }
992
993 /**
994 * @abstract

Callers 1

astGenericMethod · 0.95

Calls 2

astErrorOutputMethod · 0.95
astGenericMethod · 0.95

Tested by

no test coverage detected