haxe icon indicating copy to clipboard operation
haxe copied to clipboard

Add Context.storeType

Open back2dos opened this issue 7 years ago • 1 comments

I'd like something like Context.storeTypedExpr for types.

In tink_macro this behavior is emulated per @:genericBuild class DirectType<@const Id> {} where the type is stored with a numerical id and then looked up again by id in the generic build macro.

I would very much like for this to be part of the compiler though, especially since calls like TypeTools.toComplexType could use it to represent everything (ideally it'd still try to create a proper ComplexType, but it could fill the unrepresentable blanks with something better than null).

back2dos avatar Dec 01 '17 14:12 back2dos

Linking relevant branch: https://github.com/HaxeFoundation/haxe/tree/store_type

back2dos avatar Jul 14 '22 08:07 back2dos