On Oct 27, 2008, at 11:28 PM, Breton Slivka wrote:

I would argue it. You can either equivalently consider the fall through to
be a jump, or say it behaves as if the code of case 2

"as if the code of case 2 were duplicated into case 1"

- Maciej

I had a go at combining that concept with my object dispatcher
concept, to try and come up with an example of a reasonable transform
of a switch statement to a structure with equivalent function that
uses (mostly) only lambdas and expressions.

The object dispatcher is a neat trick but not a correct transform of switch, since switch compares with == rather than by converting to string like property lookup does.

 - Maciej
_______________________________________________
Es-discuss mailing list
[email protected]
https://mail.mozilla.org/listinfo/es-discuss

Reply via email to