Infix expressions
Hal Daume III
hdaume@ISI.EDU
Mon, 29 Jul 2002 13:14:44 -0700 (PDT)
> Is there any reason other than potential confusion when one of the two
> backquotes is accidentally omitted?
I thought about this a while ago and I think it probably simply has to do
with complexity of expressions. If you allow arbitrary expressions to
appear within the ticks, you have a problem with:
x `f a `b` g c` y
does this mean
(b (f a) (g c)) x y
or
f a x (g c b y)
or what?
You could impose the constraint that you can't have embedded ticks, but
this would grossify the CFG. Furthermore, you then have the case of, why
isn't this valid:
a `f (x `g` y)` b
where the embedding is unambiguous because of the parentheses. i don't
really know, but i find this fairly difficult to read.
a `h` b where h = x `g` y
is a lot simpler imo...
- Hal