# Re: a GCC question

- From: David Edelsohn \<hidden\>
- Date: 2000-08-06 04:57:43 
- List: linuxppc-dev
- Page: https://ratatoskr.run/linuxppc-dev/2000/08/9371709
- Thread: https://ratatoskr.run/linuxppc-dev/2000/08/9371709/t.md

```text

>>>>> Takashi Oe writes:

>> Even if the default is to do nothing, one always should provide a
>> default action or just break so that the density / coverage of the switch
>> statement cases is apparent.

Takashi> I don't know what the density is, but, if having a default action for
Takashi> nothing is always prefered, I'll fix it (or rather I'll ask Ben to fix
Takashi> it.)  Is it in gcc documentation or C standard somewhere?

	It's not in the documentation or in the standard.  It is good, but
not a requirements.  It helps document that the programmer knows what is
expected and sometimes helps the compiler generate better code by knowing
what cases need be considered.

David

** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/
```
