8 Jul
2020
8 Jul
'20
9:18 a.m.
On Wed, 8 Jul 2020, Rhodri James wrote:
On 08/07/2020 11:05, Federico Salerno wrote:
What I don't like is the use of _ as catch-all, which is different and not interdependent with its use as throwaway.
Any name used as a pattern is a catch-all. The only difference between "case dummy:" and "case _:" is that "_" doesn't bind to the thing being matched, but "dummy" does bind to it.
Does "_" really deserve that special treatment ? If you don't want to bind to it, you can just use some other dummy, same way you don't use "case print:" if you don want to bind that. /Paul