News for hackers. Stuff that matters.
Re:"Useless Ruby sugar": Pattern matching (Pt. 2) by joemi on Friday October 27, 2023 @06:06PM (#38044602)
Thanks zverok. This helped me under stand pattern matching in Ruby better than any other articles I've read on the subject. I still don't really like it in Ruby (for some of the reasons pointed out in Irks And Quirks in this article) and don't think I'll be using it in my own Ruby programs (for now). But at least now I think I understand it well enough that I won't be totally confused when I see it show up in code. And I'll admit, I'm kind of intrigued by some possible use cases... specifically case-in seems like the way I'm most likely to one day use pattern matching.

There are no comments on this comment yet.