note 90377 deleted from control-structures.switch by danbrown
| From: | danbrown@php.net | Date: | Sun, 19 Apr 2009 02:49:00 +0000 |
| Subject: | note 90377 deleted from control-structures.switch by danbrown | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-153477@lists.php.net to get a copy of this message | ||
Note Submitter: pete at gohelp dot org dot uk
----
I found this page when I was trying to remember if the PHP switch statement allowed expressions as
well as literals as the predicate of a case clause.
Logically it should, but this isn't made clear in the documentation above or, for that matter,
in O'Reilly's 'Programming PHP'.
Having written C for some 20 years, I'd stuck to literals.
Now I realise that I can vastly simplify some spaghetti code :-)