From f67390463dfbbe263288f94d41faf3249a361db6 Mon Sep 17 00:00:00 2001 From: Andy Hanson Date: Mon, 17 Sep 2018 16:04:03 -0700 Subject: [PATCH] Remove duplicate case in parseJsDocCommentWorker --- src/compiler/parser.ts | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/src/compiler/parser.ts b/src/compiler/parser.ts index 33829fccb7a7d..9c8f65fdccf11 100644 --- a/src/compiler/parser.ts +++ b/src/compiler/parser.ts @@ -6441,13 +6441,6 @@ namespace ts { indent += asterisk.length; } break; - case SyntaxKind.Identifier: - // Anything else is doc comment text. We just save it. Because it - // wasn't a tag, we can no longer parse a tag on this line until we hit the next - // line break. - pushComment(scanner.getTokenText()); - state = JSDocState.SavingComments; - break; case SyntaxKind.WhitespaceTrivia: // only collect whitespace if we're already saving comments or have just crossed the comment indent margin const whitespace = scanner.getTokenText(); @@ -6462,7 +6455,9 @@ namespace ts { case SyntaxKind.EndOfFileToken: break loop; default: - // anything other than whitespace or asterisk at the beginning of the line starts the comment text + // Anything else is doc comment text. We just save it. Because it + // wasn't a tag, we can no longer parse a tag on this line until we hit the next + // line break. state = JSDocState.SavingComments; pushComment(scanner.getTokenText()); break;