java
out/java/repro/FooBarViaAttr.java: NULL_VAL((short)254);
out/java/repro/FooBarViaType.java: NULL_VAL((short)254);
cpp
out/cpp/repro/FooBarViaAttr.h: NULL_VALUE = static_cast<std::uint8_t>(254)
out/cpp/repro/FooBarViaType.h: NULL_VALUE = static_cast<std::uint8_t>(254)
go
out/golang/repro/FooBarViaAttr.go:var FooBarViaAttr = FooBarViaAttrValues{0, 1, 254}
out/golang/repro/FooBarViaType.go:var FooBarViaType = FooBarViaTypeValues{0, 1, 254}
rust
out/rust/repro/src/foo_bar_via_attr.rs: NullVal = 0xff_u8,
out/rust/repro/src/foo_bar_via_type.rs: NullVal = 0xff_u8,
So rust is the odd one out in not changing the encoding of the null value.
Given the included xml and reproducer script, one gets
So rust is the odd one out in not changing the encoding of the null value.
enum-null-value.xml
run.sh