Hacker News new | ask | show | jobs
by elcritch 1055 days ago
You might like Patty. It makes case types more ergonomic: https://github.com/andreaferretti/patty
1 comments

Neat! Thanks for sharing. This might come in handy, although the constraint of unique field names across variant cases is still there.
Yah it's annoying, but I just rename one. Beff331 made a lib that uses tuples and avoids the naming issue: https://github.com/beef331/fungus