toml
toml copied to clipboard
Error when trying to serialize untagged enums
Here's the playground to reproduce the issue. It panics with UnsupportedType(Some("Magic"))
serde_json
can do it, but toml
cant.
This works again: https://play.rust-lang.org/?version=stable&mode=debug&edition=2021&gist=c8b2eef4cc3ec5e6c6313f217876dbd8
Same is true for this: https://play.rust-lang.org/?version=stable&mode=debug&edition=2021&gist=1ba661d64abfd56fb307a11a67b916cf
So, to me it looks related to anonymous structs as enum variant.