MCPcopy Index your code
hub / github.com/nodejs/node / grammarErrorOnNode

Function grammarErrorOnNode

test/fixtures/snapshot/typescript.js:88922–88929  ·  view source on GitHub ↗
(node, message, arg0, arg1, arg2)

Source from the content-addressed store, hash-verified

88920 return false;
88921 }
88922 function grammarErrorOnNode(node, message, arg0, arg1, arg2) {
88923 var sourceFile = ts.getSourceFileOfNode(node);
88924 if (!hasParseDiagnostics(sourceFile)) {
88925 diagnostics.add(ts.createDiagnosticForNode(node, message, arg0, arg1, arg2));
88926 return true;
88927 }
88928 return false;
88929 }
88930 function checkGrammarConstructorTypeParameters(node) {
88931 var jsdocTypeParameters = ts.isInJSFile(node) ? ts.getJSDocTypeParameterDeclarations(node) : undefined;
88932 var range = node.typeParameters || jsdocTypeParameters && ts.firstOrUndefined(jsdocTypeParameters);

Callers 15

checkAssertionFunction · 0.85
checkTupleTypeFunction · 0.85
checkGrammarMappedTypeFunction · 0.85
checkInferTypeFunction · 0.85
checkImportTypeFunction · 0.85
checkNamedTupleMemberFunction · 0.85
checkForOfStatementFunction · 0.85
checkSwitchStatementFunction · 0.85
checkLabeledStatementFunction · 0.85

Calls 2

hasParseDiagnosticsFunction · 0.85
addMethod · 0.65

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…