mirror of
https://github.com/bevyengine/bevy
synced 2024-12-30 06:53:13 +00:00
3a93b677a1
# Objective Allow `Box<dyn Reflect>` to be converted into a `Box<dyn MyTrait>` using the `#[reflect_trait]` macro. The other methods `get` and `get_mut` only provide a reference to the reflected object. ## Solution Add a `get_boxed` method to the `Reflect***` struct generated by the `#[reflect_trait]` macro. This method takes in a `Box<dyn Reflect>` and returns a `Box<dyn MyTrait>`. Co-authored-by: MrGVSV <49806985+MrGVSV@users.noreply.github.com> |
||
---|---|---|
.. | ||
src | ||
Cargo.toml |