forked from AssemblyScript/assemblyscript
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: improve diagnose for invalid generic function call
Fixes AssemblyScript#2780
- Loading branch information
1 parent
af2a250
commit 341def6
Showing
3 changed files
with
36 additions
and
0 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
true<false>(true); | ||
a<12345>() => {}; | ||
a<12345>() : void => {}; | ||
1 < 2,3,4 > (1,2,3); | ||
{ | ||
a<12345>(); | ||
} | ||
{ | ||
1 + a<12345>() + 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,8 @@ | ||
true < false > (true); | ||
a < 12345 > () => {}; | ||
a < 12345 > (): void => {}; | ||
1 < 2,3,4 > (1,2,3); | ||
{} | ||
{} | ||
// ERROR 1110: "Type expected." in diagnose-generic.ts(6,5+5) | ||
// ERROR 1110: "Type expected." in diagnose-generic.ts(9,9+5) |