Re: GOTO and/or BREAK LABEL
| From: | Xuefer | Date: | Thu, 09 Mar 2006 03:19:17 +0000 |
| Subject: | Re: GOTO and/or BREAK LABEL | ||
| References: | 1 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-22265@lists.php.net to get a copy of this message | ||
> If the "Java-like" syntax is seen as confusing, what about, as in some other
> languages, interpolating the label into the for/foreach/while statement:
>
> for (....) label {...} or for label (...) {...}
a. label: for (....) { break label; } AND label: { for (....) {
break label; } } (see
http://www.rgagnon.com/javadetails/java-0500.html
)
b. for (....) label { break label; }
c. for (....) { break label; } label:
ok, i was +1 for c, but +1 for b now.
only use "Java-like" syntax if "goto" will never be implemented