@@ -332,6 +332,8 @@ function resetNodeTextRangeToPreventDuplicateComments<T extends ts.Node>(node: T
332
332
* Reads in the leading comment text ranges of the given node,
333
333
* converts them into `ts.SyntheticComment`s and stores them on the node.
334
334
*
335
+ * Note: This would be greatly simplified with https://github.com/Microsoft/TypeScript/issues/17615.
336
+ *
335
337
* @param lastCommentEnd The end of the last comment
336
338
* @return The end of the last found comment, -1 if no comment was found.
337
339
*/
@@ -357,6 +359,8 @@ function synthesizeLeadingComments(
357
359
* Reads in the trailing comment text ranges of the given node,
358
360
* converts them into `ts.SyntheticComment`s and stores them on the node.
359
361
*
362
+ * Note: This would be greatly simplified with https://github.com/Microsoft/TypeScript/issues/17615.
363
+ *
360
364
* @return The end of the last found comment, -1 if no comment was found.
361
365
*/
362
366
function synthesizeTrailingComments ( sourceFile : ts . SourceFile , node : ts . Node ) : number {
@@ -418,6 +422,8 @@ function visitNodeStatementsWithSynthesizedComments<T extends ts.Node>(
418
422
*
419
423
* A Detached leading comment is the first comment in a SourceFile / Block
420
424
* that is separated with a newline from the first statement.
425
+ *
426
+ * Note: This would be greatly simplified with https://github.com/Microsoft/TypeScript/issues/17615.
421
427
*/
422
428
function synthesizeDetachedLeadingComments (
423
429
sourceFile : ts . SourceFile , node : ts . Node , statements : ts . NodeArray < ts . Statement > ) :
@@ -445,6 +451,8 @@ function synthesizeDetachedLeadingComments(
445
451
*
446
452
* A Detached trailing comment are all comments after the first newline
447
453
* the follows the last statement in a SourceFile / Block.
454
+ *
455
+ * Note: This would be greatly simplified with https://github.com/Microsoft/TypeScript/issues/17615.
448
456
*/
449
457
function synthesizeDetachedTrailingComments (
450
458
sourceFile : ts . SourceFile , node : ts . Node , statements : ts . NodeArray < ts . Statement > ) :
0 commit comments