Re: Little question about switch CS
| From: | Mika Tuupola | Date: | Fri, 14 Jan 2005 09:22:52 +0000 |
| Subject: | Re: Little question about switch CS | ||
| References: | 1 | Groups: | php.pear.qa |
| Request: | Send a blank email to pear-qa+get-2329@lists.php.net to get a copy of this message | ||
On Thu, 13 Jan 2005, Daniel Convissor wrote:
> I prefer the following for both short and long:
>
> switch (condition) {
> case 1:
> action1;
> break;
>
> case 2:
> action2;
> break;
>
> default:
> defaultaction;
> }
I prefer this too. Although I tend to like to have the
break after default too for the reasons Patrin explained
in his mail.
--
Mika Tuupola http://www.appelsiini.net/~tuupola/