Re: If you were to implement the original relation algebra language...

From: Marshall Spight <mspight_at_dnai.com>
Date: Sun, 23 Nov 2003 01:00:16 GMT
Message-ID: <AETvb.279515$Tr4.859792_at_attbi_s03>


"Bob Badour" <bbadour_at_golden.net> wrote in message news:m_2dnes63Z0zKSKiRVn-vg_at_golden.net...
> "Marshall Spight" <mspight_at_dnai.com> wrote in message
> news:Q6Ovb.208724$275.779602_at_attbi_s53...
> >
> > I think we would be better off providing the language with enough
> > flexibility so that the programmer can choose the most appropriate
> > form of expression at the time. cf. Haskell.
>
> Are you suggesting you prefer redundant languages?

Sometimes I have trouble understanding what you mean because you are so very terse.

I think my feeling towards redundancy in languages is that it's useful in modest amounts. I think Perl's TMTOWTDI attitude is suboptimal, but I don't think I'd like a language that was at the opposite extreme any more.

In particular, I don't want a language to restrict itself exclusively to infix operators, or to restrict itself exclusively to prefix operators. I don't like Lisp's prefix-only syntax much, for example.

Traditional prefixed function-call syntax works pretty well, but binary arithmetic operators work best as infix.

But of all the choices for prefix vs. infix, I think I like Haskell's best. You can declare your own operators, and they can be infix or prefix. With special syntax, you can use infix operators as prefix operators, and vice versa. With modest usage, this improves clarity.

I'm happy giving the programmer the flexibility to pick the right syntax for the current context. YMMV.

Marshall Received on Sun Nov 23 2003 - 02:00:16 CET

Original text of this message