impl dyn Any for monomorphized dyn Trait #2571
Labels
A-trait-object
Proposals relating to trait objects.
T-lang
Relevant to the language team, which will review and decide on the RFC.
there's no reason why stuff like this shouldn't be made more friendly and optimized (I shouldn't need two boxes for it to work): https://play.rust-lang.org/?version=stable&mode=debug&edition=2015&gist=7281cea78856a6bc6c8693dcb320b9d0
note that I'm talking specifically about
fn<T: Foo>(t: T) -> Box<dyn Any>
kinda usage. you wouldn't be able to take an arbitrarydyn Foo
and turn it into andyn Any
(yet).The text was updated successfully, but these errors were encountered: