Date: Wed, 19 Nov 1997 16:32:22 -0800
Reply-To: REXX Programming discussion list <REXXLIST@UGA.CC.UGA.EDU>
Sender: REXX Programming discussion list <REXXLIST@UGA.CC.UGA.EDU>
From: "Shmuel (Seymour J.) Metz" <nospam@GSG.EDS.COM>
Organization: EDS MS
Subject: Re: regular expression matching
Content-Type: text/plain; charset=us-ascii
Patrick Herring wrote:
> Agreed by me.
I'll have to dig up my copy of the "Dragon Nook" and see how they define
it. I recall the definition as including balanced parentheses, but
perhaps I'm confusing it with SNOBOL patterns, which definitely had such
> We've had several threads here in the past as to how to
> integrate REs with Rexx, either in some form of the parse command or
> perhaps as a BIF.
Personally I think that we should look at how patterns are defined in
SNOBOL 4, SL5 and Icon.
> The problems always seemed to be to keep the Rexxish
> way of quoting literals etc, the way blanks between tokens are sometimes
> significant as operators, and how to specify variable names for the
> matched strings when the syntax for variable names is so loose. It would
> be good to hear any ideas on this you may have.
Well, keeping REXX syntax for literals and variables is easy, but
keeping REXX syntax for concatenation (using abuttment) is stickier.
> Personally I entirely agree that parse is a) not parsing, b) odd, & c)
> unnecessarily weak compared with other mechanisms.
It's a bit harsh to say that it's not parsing, but it's certainly an
emascultated form of parsing.
> LR parsing by BNF grammars.
Both too strong and too weak. Full BNF grammars would add a lot of
baggage to the language, and might not be worth the cost. OTOH, if
you're going to go that far, you may as well use a syntax with more
expressive power than BNF. Attribute grammars come to mind, as do the
mechanisms used to define ALGOL 68 (W grammars) and PL/I.
Shmuel (Seymour J.) Metz
Senior Software SE
The values in from and reply-to are for the benefit of spammers:
reply to domain eds.com, user msustys1.smetz or to domain gsg.eds.com,
user smetz. Do not reply to email@example.com