Re: New switch/case idea
- Posted by DerekParnell (admin) Apr 06, 2009
- 1661 views
DerekParnell said...
That should still work in Euphoria too, but it doesn't at the moment. I think this is a bug. To get it to work currently you have to add a label to the break clause...
switch X label "A" do case 1 then . . . if cond then break "A" end if
Oops, no its not a bug. The break statement can also be used inside if statements to break out of a deeply nested if. So a break without a label and inside an if just skips to the end if line.