-
-
Notifications
You must be signed in to change notification settings - Fork 647
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix forced constructor creation (closes #4557)
Instead of not generating constructor for classes that extend a forced constructor class, we create a constructor but retain the `@:compilerGenerated` metadata.
- Loading branch information
Showing
2 changed files
with
27 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
package unit.issues; | ||
|
||
private class Ghost { | ||
public var value:String; | ||
public function new(value) { | ||
this.value = value; | ||
} | ||
} | ||
|
||
private class A { | ||
public var ghost = new Ghost("booh!"); | ||
} | ||
|
||
private class B extends A { } | ||
|
||
private class C extends B { | ||
public function new() { } | ||
} | ||
|
||
class Issue4557 extends Test { | ||
function test() { | ||
var c = new C(); | ||
eq("booh!", c.ghost.value); | ||
} | ||
} |
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