Date: Tue, 9 Apr 2002 16:40:56 -0700 (PDT)
From: Paul Eggert <yyyyyy@xxxxxxxxxxx>
> > Date: Tue, 9 Apr 2002 15:54:24 -0700 (PDT)
> > From: Tom Lord <yyyy@xxxxxxxxxxx>
>
> > I favor the left-associative interpretation because:
> >
> > 1. It's what the grammar says.
>
> Hard to argue with that.
Sorry for repeating, but I haven't understood why the semantics is
restricted by the definition method of the syntax yet.
The standard says "all semantic requirements are described only in
textual form". (I omitted the context here, please see the full text
<http://www.opengroup.org/onlinepubs/007904975/utilities/xcu_chap01.html#tag_01_10>)
And the text doesn't say "also the semantics is right-associative",
but says "left to right".
> So if common theoretical computer science tradition holds weight, we
> should leave the POSIX RE grammar alone, and keep it left-associative.
Could you please give me more explanation?
Common theoretical computer science tradition seems to treat RE
concatination as a logically associative operator, then the grammar may
make it either left-associative or right-associative.
Thanks,
--
Isamu Hasegawa
IBM Japan, Ltd.
|