Allow #[inject] attribute on unnamable fields
Nashenas88 opened this issue · 0 comments
Nashenas88 commented
Currently, tuples and tuple structs cannot be used with #[derive(Inject)]
or #[inject]
. It should be possible for the #[inject]
attribute to get parameters, one of which could be the name to use when injecting. For example:
#[derive(Inject)]
#[provides(dyn Trait1 with Impl1(unnamed))]
struct Impl1(#[inject(unnamed)] Arc<dyn Dep>);