Open MSGhero opened 7 years ago
Inlining + @:multiType
is such a big problem even for our Map implementation. I'm considering getting rid of @:multiType
entirely in favor of something more robust, but I have yet to come up with something that's actually more robust.
A multityped abstract over a multityped abstract over an interface provides unexpected behavior if the outermost abstract has inlined
@:to
converters.inline
or not in the inner abstract's@:to
does not appear to matter.Explanation of code:
new A<Int>()
should result in aC
being created, tracing out "C".new A<String>()
should result inD
and "D". Because the string path's@:to
is inlined, it seems like aB
is being created and used instead of aD
even thoughB
is abstract.Note: if
A,B,C,D
have a parameter in their constructors,new A<String>("param")
will cause a runtime error for too many arguments. However, deleting the argument leads to a compile time error for not enough arguments, which is expected.(sorry if there's a more minimal example)
Relevant js output:
Haxe 3.4.2 master and latest dev if I installed it properly