Re: New construct discussion Summary (was: what happened to that new isset() like language construct)
| From: | l0t3k | Date: | Mon, 12 Jul 2004 12:24:05 +0000 |
| Subject: | Re: New construct discussion Summary (was: what happened to that new isset() like language construct) | ||
| References: | 1 2 3 4 5 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-11119@lists.php.net to get a copy of this message | ||
"Andi Gutmans" <andi@zend.com> wrote in message
news:5.1.0.14.2.20040711205308.033261e8@127.0.0.1...
> How about default($var, expr)?
my only reservation is that "default" is already part of a language
construct :
<code>
switch ($param = $_GET["param"]) {
case "foo" : bar(); break;
case "this" : that(); break;
default:
the_other( default($param) );
}
</code>
i'd say use defaultvalue