impl_from_reflect_opaque!() { /* proc-macro */ }
Expand description
A macro used to generate a FromReflect
trait implementation for the given type.
This is functionally the same as deriving FromReflect
on a type that derives Reflect
using
the #[reflect(opaque)]
container attribute.
The only reason this macro exists is so that bevy_reflect
can easily implement FromReflect
on
primitives and other opaque types internally.
Please note that this macro will not work with any type that derives Reflect
normally
or makes use of the impl_reflect_opaque!
macro, as those macros also implement FromReflect
by default.
§Examples
ⓘ
impl_from_reflect_opaque!(foo<T1, T2: Baz> where T1: Bar);