Mail Archives: djgpp/2002/05/20/03:32:54
On Sun, 19 May 2002, Pedro Izecksohn wrote:
> Wouldn't be great if it was possible to compile the code
> bellow ? I know the compiler's problem with it, but what is
> the logical problem ? Hasn't English some words that they
> have differents meanings in different phrases ?
>
> #define something enum something
> something {
> a,b,c,d,e };
>
> #define otherthing enum otherthing
> otherthing {
> a,s,d,f,g };
AFAIK, the C Standard rules that all the enumeration constants in the
same file share the same namespace. So the Standard disallows what you
want to do.
- Raw text -