-
Notifications
You must be signed in to change notification settings - Fork 109
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
tsickle: emit comment after missing semicolon only once
PiperOrigin-RevId: 585982807
- Loading branch information
1 parent
d5c2921
commit 209d420
Showing
5 changed files
with
46 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
/** | ||
* | ||
* @fileoverview Tests that the JSDoc comment of `other` is only emitted once. | ||
* Without the trailing semicolon after `noExplicitSemicolon` TypeScript seems | ||
* to duplicate the trailing comment as soon as a custom transformer modifies | ||
* the variable statement. | ||
* | ||
* Generated from: test_files/comments/trailing_no_semicolon.ts | ||
*/ | ||
goog.module('test_files.comments.trailing_no_semicolon'); | ||
var module = module || { id: 'test_files/comments/trailing_no_semicolon.ts' }; | ||
goog.require('tslib'); | ||
/** @type {number} */ | ||
const noExplicitSemicolon = 0; | ||
/** | ||
* This is a comment with a JSDoc tag | ||
* JSCompiler doesn't recognize | ||
* | ||
* \@foobar | ||
* @type {number} | ||
*/ | ||
exports.other = 1; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
/** | ||
* @fileoverview Tests that the JSDoc comment of `other` is only emitted once. | ||
* Without the trailing semicolon after `noExplicitSemicolon` TypeScript seems | ||
* to duplicate the trailing comment as soon as a custom transformer modifies | ||
* the variable statement. | ||
*/ | ||
|
||
|
||
const noExplicitSemicolon = 0 | ||
|
||
/** | ||
* This is a comment with a JSDoc tag | ||
* JSCompiler doesn't recognize | ||
* | ||
* @foobar | ||
*/ | ||
export const other = 1; |