From: | Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | Thomas Lockhart <lockhart(at)fourpalms(dot)org>, Peter Eisentraut <peter_e(at)gmx(dot)net>, pgsql-patches(at)postgresql(dot)org |
Subject: | Re: Call for objections: revision of keyword classification |
Date: | 2001-11-09 04:04:17 |
Message-ID: | 200111090404.fA944HI15308@candle.pha.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers pgsql-patches |
> Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us> writes:
> > Can we move the keywords out into another file and somehow pull them
> > into gram.y with the proper attributes so they get into all the places
> > they need to be with little fiddling?
>
> Thinking about that, it seems like it might be nice to have a master
> keyword file that contains just keywords and classifications:
>
> AS Hard-reserved
> CASE ColLabel
> ABSOLUTE TypeFuncId
> BIT ColId
>
> and make some scripts that generate both keyword.c and the list
> productions in gram.y automatically. (Among other things, we could stop
> trusting manual sorting of the keyword.c entries ...) Peter's
> documentation generator would no doubt be a lot happier too --- we
> could add indications of SQL92 and SQL99 reserved status to this
> master file, for example.
>
> However, right offhand I don't see any equivalent of #include in the
> Bison manual, so I'm not sure how the autogenerated list productions
> could be included into the hand-maintained part of gram.y. Thoughts?
Yes, this is what I was suggesting; a central file that can be pulled
in to generate the others.
Doesn't bison deal with #include? I guess not. The only other way is
to make a gram.y.pre, and have Makefile do the inclusions in the proper
spot, and run that new gram.y through bison. The fact is, you have to
process the central file anyway so may as well just do the gram.y
replacements manually too.
--
Bruce Momjian | http://candle.pha.pa.us
pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 853-3000
+ If your life is a hard drive, | 830 Blythe Avenue
+ Christ can be your backup. | Drexel Hill, Pennsylvania 19026
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2001-11-09 04:08:17 | Re: Small FK patch to deal with tables without oids |
Previous Message | Barry Lind | 2001-11-09 03:27:18 | Re: [HACKERS] MD5-based passwords |
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2001-11-09 04:07:05 | Re: Patch for Makefile race against current cvs |
Previous Message | Tom Lane | 2001-11-09 02:48:51 | Re: Call for objections: revision of keyword classification |