@PythOnRails to Python • 10 months agoThe Python dictionary dispatch patternjamesg.blogexternal-linkmessage-square10arrow-up133arrow-down10cross-posted to: [email protected]
arrow-up133arrow-down1external-linkThe Python dictionary dispatch patternjamesg.blog@PythOnRails to Python • 10 months agomessage-square10cross-posted to: [email protected]
minus-square@[email protected]linkfedilink3•10 months agoI think a similar result might now be achievable with match statements
minus-square@[email protected]linkfedilink0•10 months agoMatch only just came out in Python 3.10, so it doesn’t universally work. I think you implied that in your comment, so I wanted to add context for others.
minus-square@[email protected]linkfedilink2•10 months agoOh, yes. I’m excited for the arrival of match. I’ve used it in rust and it’s very nifty and Pythonic
I think a similar result might now be achievable with match statements
Match only just came out in Python 3.10, so it doesn’t universally work. I think you implied that in your comment, so I wanted to add context for others.
Oh, yes. I’m excited for the arrival of match. I’ve used it in rust and it’s very nifty and Pythonic