Retain space after first word in multiline jsdoc

For words that were shorter than the jsdoc indent level, the space was
omitted previously.
This commit is contained in:
Nathan Shively-Sanders 2016-11-10 13:11:32 -08:00
parent 28cc938503
commit 8bd0a47c82
2 changed files with 3 additions and 1 deletions

View file

@ -6238,6 +6238,7 @@ namespace ts {
}
if (token() === SyntaxKind.NewLineTrivia) {
state = JSDocState.BeginningOfLine;
indent = 0;
nextJSDocToken();
}
while (token() !== SyntaxKind.EndOfFileToken) {

View file

@ -3,6 +3,7 @@
// @Filename: Foo.js
/////**
//// * Represents a person
//// * a b multiline test
//// * @constructor
//// * @param {string} name The name of the person
//// * @param {number} age The age of the person
@ -13,4 +14,4 @@
////}
////var p = new Pers/**/on();
goTo.marker();
verify.quickInfoIs("function Person(name: string, age: number): void", "Represents a person");
verify.quickInfoIs("function Person(name: string, age: number): void", "Represents a person\na b multiline test");