MixinExtras
MixinExtras copied to clipboard
[Suggestion] Way to intentionally share a `@Share` between two mixins
a @Share
is unique to a mixin, which is very good for compatibility, but that behavior can occasionally be desired.
For Porting Lib, I need to wrap a parameter as early as possible, and then access it later as late as possible.
I am doing this with two mixins, one with low priority, and one with high. Since it's split, I can't use a @Share
, and I'll have to use a ThreadLocal.
I think a solution would be to have an option to expand the scope to within the current mixin config, if that's possible.
I think the most general solution would be to allow you to specify a namespace
, which would default to the name of your mixin (the current behaviour).
It can't default to exactly the name of your mixin, because mixin names are fairly standardized. For example, the number of MixinBlock
/BlockMixin
or MixinLivingEntity
/LivingEntityMixin
are probably in the thousands.
The fully qualified name.
Fair enough