From: | gah4 <gah4@u.washington.edu> |
Newsgroups: | comp.compilers |
Date: | Sat, 3 Dec 2022 17:15:55 -0800 (PST) |
Organization: | Compilers Central |
References: | 22-12-001 22-12-005 |
Injection-Info: | gal.iecc.com; posting-host="news.iecc.com:2001:470:1f07:1126:0:676f:7373:6970"; logging-data="82631"; mail-complaints-to="abuse@iecc.com" |
Keywords: | syntax |
Posted-Date: | 03 Dec 2022 23:00:17 EST |
In-Reply-To: | 22-12-005 |
On Saturday, December 3, 2022 at 4:27:51 PM UTC-8, christoph...@compiler-resources.com wrote:
> The discussion on reserved words versus keywords reminds me of
> decisions we made while building Yacc++. It is worth noting that we
> (both of its developers) worked at Pr1me computer where PL/I dialects
> were the key programming language used in build both the OS and the
> compilers, so we were likely highly influenced by that.
This is reminding me of some cases in TeX where optional keywords can
arise in unexpected places. There is TeX glue that allows:
\hskip 1cm
or
\hskip 1cm plus 1cm
In normal use, you mix TeX commands and text to be formatted. If a macro
expands to
\hskip 1cm
and is followed by text starting with
plus
you get a surprising error message.
I believe that plus is only a "reserved word" in that specific context.
And a project I was working on some years ago, just happened to run
into that case, however unlikely that might be.
Return to the
comp.compilers page.
Search the
comp.compilers archives again.