> where is it determined that LNAME is returned when *t is scanned
> rather than LTYPE (the way it is returned in the declaration of foo)?

grep shows that /sys/src/cmd/cc/lex.c is relevant,
since it contains

        s = lookup();
        if(s->macro) {
                ...
        }
        yylval.sym = s;
        if(s->class == CTYPEDEF || s->class == CTYPESTR)
                return LTYPE;
        return s->lexical;

for the relevant bit of lexing.  you could trace back and 
see how s->class gets set.

russ

Reply via email to