-
-
Notifications
You must be signed in to change notification settings - Fork 661
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[macro] Don't choke on namePos for reification pattern matching (#11671)
* [macro] Don't choke on namePos for reification pattern matching * [tests] Add test for 11670 * Do it like in #11433
- Loading branch information
Showing
4 changed files
with
23 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,16 @@ | ||
class Main { | ||
static function main() { | ||
test(var foo:String); | ||
} | ||
|
||
static macro function test(e) { | ||
switch e { | ||
// Unrecognized pattern: untyped $__mk_pos__("Test.hx", 145, 150) | ||
case macro var $name:$ct: | ||
case _: | ||
} | ||
|
||
return macro {}; | ||
} | ||
} | ||
|
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 @@ | ||
-main Main |
Empty file.