Merge pull request #18014 from Microsoft/allow-bang+dotdotdot-as-start-of-type

Allow bang+dotdotdot as start of type
This commit is contained in:
Nathan Shively-Sanders
2017-09-01 14:26:16 -07:00
committed by GitHub
4 changed files with 37 additions and 1 deletions

View File

@@ -2724,6 +2724,8 @@ namespace ts {
case SyntaxKind.ObjectKeyword:
case SyntaxKind.AsteriskToken:
case SyntaxKind.QuestionToken:
case SyntaxKind.ExclamationToken:
case SyntaxKind.DotDotDotToken:
return true;
case SyntaxKind.MinusToken:
return lookAhead(nextTokenIsNumericLiteral);