|
|
|
|
|
by afdbcreid
19 days ago
|
|
Why do you need to do that? You can't be generic over "any enum using this tag" anyway (in Rust, at least). If you just want to make sure you make no mistake, you can use a dead match from the tag to the enum, or automate it with a macro, and the compiler will enforce exhaustiveness (though not on both sides, unless you use a macro). |
|
EDIT: Run on sentence broken up.