-
Notifications
You must be signed in to change notification settings - Fork 12.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
By copying the kludge in @typedef. @callback's order is simpler, so the kludge is simpler. However, it's wrong here, and in @typedef. Parsing tag comments is normally supposed to happen at the end of a tag, but in @callback and @typedef happens *before* parsing the nested @param/@Property tags. I still need to figure out what a real fix is -- but for the beta, copying the existing crash-avoidance kludge from @typedef is best anyway. I added a test case for typedefs for future use as well.
- Loading branch information
Showing
4 changed files
with
59 additions
and
1 deletion.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
/// <reference path='fourslash.ts' /> | ||
// @Filename: foo.js | ||
// @allowJs: true | ||
// @checkJs: true | ||
//// /** @callback Listener @yeturn {ListenerBlock} */ | ||
//// /** | ||
//// * The function used | ||
//// * /*1*/ settings | ||
//// */ | ||
//// class /*2*/ListenerBlock { | ||
//// } | ||
|
||
// Force a syntax tree to be created. | ||
verify.noMatchingBracePositionInCurrentFile(0); | ||
|
||
goTo.marker('1'); | ||
edit.insert('fenster'); | ||
|
||
verify.quickInfoAt('2', 'class ListenerBlock', 'The function used\nfenster settings') |
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,19 @@ | ||
/// <reference path='fourslash.ts' /> | ||
// @Filename: foo.js | ||
// @allowJs: true | ||
// @checkJs: true | ||
//// /** @callback Listener @param x @yeturn {ListenerBlock} */ | ||
//// /** | ||
//// * The function used | ||
//// * /*1*/ settings | ||
//// */ | ||
//// class /*2*/ListenerBlock { | ||
//// } | ||
|
||
// Force a syntax tree to be created. | ||
verify.noMatchingBracePositionInCurrentFile(0); | ||
|
||
goTo.marker('1'); | ||
edit.insert('fenster'); | ||
|
||
verify.quickInfoAt('2', 'class ListenerBlock', 'The function used\nfenster settings') |
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,19 @@ | ||
/// <reference path='fourslash.ts' /> | ||
// @Filename: foo.js | ||
// @allowJs: true | ||
// @checkJs: true | ||
//// /** @typedef Lister @property p @yeturn {ListenerBlock} */ | ||
//// /** | ||
//// * The function used | ||
//// * /*1*/ settings | ||
//// */ | ||
//// class /*2*/ListenerBlock { | ||
//// } | ||
|
||
// Force a syntax tree to be created. | ||
verify.noMatchingBracePositionInCurrentFile(0); | ||
|
||
goTo.marker('1'); | ||
edit.insert('fenster'); | ||
|
||
verify.quickInfoAt('2', 'class ListenerBlock', 'The function used\nfenster settings') |