-
-
Notifications
You must be signed in to change notification settings - Fork 655
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[analyzer] don't recursively check enum values when const propagating
closes #11429
- Loading branch information
Showing
2 changed files
with
21 additions
and
2 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,19 @@ | ||
package unit.issues; | ||
|
||
private enum Foo { | ||
FooRec(foo:Foo); | ||
} | ||
|
||
class Issue11429 extends Test { | ||
function test() { | ||
blowUp([]); | ||
utest.Assert.pass(); | ||
} | ||
|
||
public static function blowUp(arr:Array<Foo>) { | ||
var qp = FooRec(arr.pop()); | ||
while (arr.length > 0) { | ||
qp = FooRec(qp); | ||
} | ||
} | ||
} |