Open exzachlyvv opened 6 months ago
I don't know any way to not show those errors. I created #2742 which adds another error saying "Serde's `tag` attribute requires either "alloc" or "std" feature to be enabled on the serde crate", but I don't know if this is really better.
I think I would lean toward just adding documentation in whatever is the right place. This is already documented in https://serde.rs/no-std.html#derive, but we can add another note about it in https://serde.rs/container-attrs.html.
I'm using a serde enum in a
#[no_std] environment
. When usingtag
, the code fails to compile with error:and
Example Code:
I have tried this same code in a std environment and it works as expected.