3 ms·
That's not the same thing. Rust enums are types, each with the possibility of having different fields that store data. Java enums are instances of a type, each
by nightpool 12y ago
That's not the same thing. Rust enums are types, each with the possibility of having different fields that store data. Java enums are instances of a type, each with static data.
(rust enums can have associated data too, but its not their main usage in idiomatic code)