mirror of
https://github.com/microsoft/TypeScript.git
synced 2026-07-02 14:48:32 -05:00
Fix the crash in completion entry by fixing the unknown token check
Fixes #1069
This commit is contained in:
@@ -224,7 +224,10 @@ module ts {
|
||||
return nodeHasTokens((<ExpressionStatement>n).expression);
|
||||
}
|
||||
|
||||
if (n.kind === SyntaxKind.EndOfFileToken || n.kind === SyntaxKind.OmittedExpression || n.kind === SyntaxKind.Missing) {
|
||||
if (n.kind === SyntaxKind.EndOfFileToken ||
|
||||
n.kind === SyntaxKind.OmittedExpression ||
|
||||
n.kind === SyntaxKind.Missing ||
|
||||
n.kind === SyntaxKind.Unknown) {
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
6
tests/cases/fourslash/completionAfterAtChar.ts
Normal file
6
tests/cases/fourslash/completionAfterAtChar.ts
Normal file
@@ -0,0 +1,6 @@
|
||||
/// <reference path='fourslash.ts'/>
|
||||
|
||||
////@a/**/
|
||||
|
||||
goTo.marker();
|
||||
verify.not.completionListIsEmpty();
|
||||
Reference in New Issue
Block a user