From 0d480a6e1b8c0bf8b8799ea70f2dab39c2ad3c88 Mon Sep 17 00:00:00 2001 From: Ryan Cavanaugh Date: Fri, 22 Jan 2016 15:15:58 -0800 Subject: [PATCH] Remove value-side JSDoc type lookup fallback --- src/compiler/checker.ts | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index fb083d5c5c2..82b6acadc5a 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -4444,14 +4444,7 @@ namespace ts { return unknownSymbol; } - let symbol = resolveEntityName(typeReferenceName, SymbolFlags.Type); - if (!symbol && node.kind === SyntaxKind.JSDocTypeReference) { - // If the reference didn't resolve to a type, try seeing if results to a - // value. If it does, get the type of that value. - symbol = resolveEntityName(typeReferenceName, SymbolFlags.Value); - } - - return symbol || unknownSymbol; + return resolveEntityName(typeReferenceName, SymbolFlags.Type) || unknownSymbol; } function getTypeReferenceType(node: TypeReferenceNode | ExpressionWithTypeArguments | JSDocTypeReference, symbol: Symbol) {