[ back to toc ]

C lang

Date: 2002/01/25 19:35

Q:
In C, 'default' is a keyword (used in the last Switch-case statement)
But, when we misspell the keyword in the switch case block(for ex as
'dfault' or as 'defualt'), it does not cause any compiler errors.Why???
A:
There can be several reasons.

1. These words are "#define"d before in the code somewhere.
2. Your compiler is boguous.

What compiler is it? What operating system do you try? Give me a sample
code.

Regards,
Peter

[ back to toc ]