Diplomat doesn't support enums where the variants have contents.
E.g.:
enum MyEnum {
A(i32), // not supported
B,
}
Right now, there is no error thrown during lowering, if some of the variants have contents. This is confusing, because then the generated code doesn't support the Rust type in the block. But potentially more importantly, this causes errors on 32-bit architecture, as the size of the enum differs in the generated C vs. what exists on the Rust side.
I think the fix would be to throw an error during lowering if the enum has a variant with contents.
Diplomat doesn't support enums where the variants have contents. E.g.:
Right now, there is no error thrown during lowering, if some of the variants have contents. This is confusing, because then the generated code doesn't support the Rust type in the block. But potentially more importantly, this causes errors on 32-bit architecture, as the size of the enum differs in the generated C vs. what exists on the Rust side.
I think the fix would be to throw an error during lowering if the enum has a variant with contents.