Hacker News new | ask | show | jobs
by stream_fusion 4424 days ago
Does this change pattern matching syntax of recursive data structures, if every node is an explicit box type? Could be cumbersome for matching parse-trees?
1 comments

I have read that is doesn't change a thing. Maybe it's even more concise.

From what I have read, there is a general mechanism for pattern matching: let the custom data structure implement a "pattern match" method or something, which is then implicitly called with the pattern matching syntax. The explicit box type would be no different.

My guess is, parse-trees would be just as easy to match.