note 14983 deleted from control-structures.break by irc-html
| From: | irc-html@php.net | Date: | Wed, 16 Jan 2002 17:09:00 +0000 |
| Subject: | note 14983 deleted from control-structures.break by irc-html | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-24937@lists.php.net to get a copy of this message | ||
return() does not perform an implicit break. The return() statement exists all the non-function
blocks within the current function AND the function block itself.
AFAIK issuing a break statement inside a function when there are no blocks from which to break will
give a fatal error. So you can never use break to exit a function, rather you must use an explicit
return() for this.