mattmoore
06/30/2020, 7:38 PMcase
synthetic to act as a marker. In the current iteration, it's looking at when
subject, but we would also need to handle the expression when it's not a when
subject or even outside when
entirely. For example:
val matt = Person("Matt", "Moore")
val Person(_, lastName) = matt
Another example would be for matching on lists (though that's not quite in scope just yet, as there's more stuff to solve there).
I'll be able to experiment more with this tonight. Of course, I'm still new to the internal APIs so having your help, Raul's help, and everyone else on that has been a tremendous boost to this effort. So thank you for that! 🙂 If I'm able to figure out how to generalize the current version without when
expressly (so it'll work in more general cases) I'll push some code up. Unless you beat me to it 😉
Thanks @Rachel for looking into 1.4. I'm very eager to see 1.4 be finally ready, as I'm sure all of you are as well 🙂case
so that might be another scenario where we need to use case
- unless we can find another way to mark that out.shikasd
06/30/2020, 8:24 PMmattmoore
06/30/2020, 8:38 PM