On 6/25/20 6:48 PM, Emily Bowman wrote:
On Thu, Jun 25, 2020 at 3:41 PM Richard Damon <Richard@damon-family.org mailto:Richard@damon-family.org> wrote:
Actually, you could make _ less special by still binding the value to
it, just make it special in that you allow several values to be bound, and maybe just define that the result will be just one of the values, maybe even specify which if you want.
Like Guido said above, the problem is that _ is already effectively reserved for translated text. Combining the two would feel a bit weird, but should still be possible.
I thought _ was also commonly used as:
first, -, last = (1, 2, 3)
as a generic don't care about assignment. I guess since the above will create a local, so not overwrite a 'global' function _ for translations, so the above usage works as long as that function (or whatever namespace you are in) doesn't use _ for translations. As long as the bindings in match also make the symbol a local (which seems reasonable) then you would get a similar restriction.