Skip to content

Commit fbe4246

Browse files
committed
Remove resolveLocation
1 parent 2c5ba08 commit fbe4246

File tree

1 file changed

+0
-17
lines changed

1 file changed

+0
-17
lines changed

src/compiler/checker.ts

Lines changed: 0 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -5841,32 +5841,15 @@ namespace ts {
58415841
}
58425842
}
58435843

5844-
function resolveLocation(node: Node) {
5845-
// Resolve location from top down towards node if it is a context sensitive expression
5846-
// That helps in making sure not assigning types as any when resolved out of order
5847-
let containerNodes: Node[] = [];
5848-
for (let parent = node.parent; parent; parent = parent.parent) {
5849-
if ((isExpression(parent) || isObjectLiteralMethod(node)) &&
5850-
isContextSensitive(<Expression>parent)) {
5851-
containerNodes.unshift(parent);
5852-
}
5853-
}
5854-
5855-
ts.forEach(containerNodes, node => { getTypeOfNode(node); });
5856-
}
5857-
58585844
function getSymbolAtLocation(node: Node): Symbol {
5859-
resolveLocation(node);
58605845
return getSymbolInfo(node);
58615846
}
58625847

58635848
function getTypeAtLocation(node: Node): Type {
5864-
resolveLocation(node);
58655849
return getTypeOfNode(node);
58665850
}
58675851

58685852
function getTypeOfSymbolAtLocation(symbol: Symbol, node: Node): Type {
5869-
resolveLocation(node);
58705853
// Get the narrowed type of symbol at given location instead of just getting
58715854
// the type of the symbol.
58725855
// eg.

0 commit comments

Comments
 (0)