I'm not sure why, but somehow #[derive(Reflect)] on a tuple struct with a boxed trait object can result in linker errors when dynamic linking is used on Windows using rust-lld:
Adding #[reflect(opaque)] to the Reflect derive fixes the problem, and that's what this patch does. I think that adding #[reflect(opaque)] is harmless, as there's little that reflection allows with a boxed trait object anyhow.
I'm not sure why, but somehow
#[derive(Reflect)]
on a tuple struct with a boxed trait object can result in linker errors when dynamic linking is used on Windows usingrust-lld
:etc.
Adding
#[reflect(opaque)]
to theReflect
derive fixes the problem, and that's what this patch does. I think that adding#[reflect(opaque)]
is harmless, as there's little that reflection allows with a boxed trait object anyhow.