On Thu Jan 18 16:14:31 2024 +0000, Giovanni Mascellani wrote:
If feels quite fragile to rely on numerical values here. I'd just enumerate the switch cases or use a static array, it's not terribly long or hard to maintain.
I think it's acceptable where the enum values are very unlikely to change in a breaking way, which is the case here.