Modifying Typedefs (And Implementing Them)
Eyal Lebedinsky
eyal at echo.canberra.edu.au
Sun Sep 16 10:58:45 AEST 1990
In article <1990Sep14.213822.4828 at uunet!unhd> al at uunet!unhd (Anthony Lapadula) writes:
>While implementing a (hopefully soon-to-be-) ANSI-compliant compiler,
>we came across the following problem. Given
[...]
> unsigned INT foo1;
3.5.2 clearly states which type-specifier lists are allowed, and this is not
one of those.
> extern INT foo2;
This is a storage-class-specifier followed by a type-specifier which is ok
for 3.5.
> extern INT (CHAR);
typedefs and variables share a common namespace to CHAR will hide the
external one.
[...]
>Doesn't the lexer have to know more? In my third example, the
>lexer needs to know that CHAR is a candidate variable, even though it
>is currently a typedef-name. How is this implemented?
I found it necessary NOT to have the lexer make the decision for the same
reason.
>
>-- Anthony (uunet!unhd!al, al at unh.edu) Lapadula
I am using the May/88 Draft.
Regards
Eyal
--
Regards
Eyal
More information about the Comp.lang.c
mailing list