You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In the former example, the a is bound to the first literal only, and in the latter the compiler thinks that it is a tuple (and complains about the lack of commas).
Of course, one can do
a @ 0x2A | a @ 0x2D | a@ 0x2E | a@ 0x30 .. 0x39 /* etc */=> {println("{}",a)}
but that is cumbersome.
Could we get a way to easily bind a variable to the entire match arm?