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

Function getBaseTypesIfUnrelated

test/fixtures/snapshot/typescript.js:79370–79380  ·  view source on GitHub ↗
(leftType, rightType, isRelated)

Source from the content-addressed store, hash-verified

79368 }
79369 }
79370 function getBaseTypesIfUnrelated(leftType, rightType, isRelated) {
79371 var effectiveLeft = leftType;
79372 var effectiveRight = rightType;
79373 var leftBase = getBaseTypeOfLiteralType(leftType);
79374 var rightBase = getBaseTypeOfLiteralType(rightType);
79375 if (!isRelated(leftBase, rightBase)) {
79376 effectiveLeft = leftBase;
79377 effectiveRight = rightBase;
79378 }
79379 return [effectiveLeft, effectiveRight];
79380 }
79381 function checkYieldExpression(node) {
79382 addLazyDiagnostic(checkYieldExpressionGrammar);
79383 var func = ts.getContainingFunction(node);

Callers 1

reportOperatorErrorFunction · 0.85

Calls 1

getBaseTypeOfLiteralTypeFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…