From: "Russ Cox" <rsc@swtch.com>
To: 9fans@cse.psu.edu
Subject: Re: [9fans] scopes in kencc
Date: Thu, 26 Apr 2007 22:04:46 -0400 [thread overview]
Message-ID: <20070427020447.C49F71E8C48@holo.morphisms.net> (raw)
In-Reply-To: <7871fcf50704261812o6379c087xdfa8b74e6fa4adf2@mail.gmail.com>
> 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
next prev parent reply other threads:[~2007-04-27 2:04 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-04-27 1:12 Joel C. Salomon
2007-04-27 2:04 ` Russ Cox [this message]
2007-04-27 2:48 ` Joel C. Salomon
2007-04-27 3:02 ` Russ Cox
2007-04-27 4:35 ` Joel C. Salomon
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20070427020447.C49F71E8C48@holo.morphisms.net \
--to=rsc@swtch.com \
--cc=9fans@cse.psu.edu \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).