[E-Lang] Operator expansion names, Part 1: Intro
Ben Laurie
ben@algroup.co.uk
Mon, 23 Apr 2001 14:34:19 +0100
"Mark S. Miller" wrote:
> For example, we might say the "normal" math notion of "+" is something like:
>
> For each data type T to which + applies (after coercions), + should
> be closed over T, such that for any t1 and t2 in T, t1 + t2 should also be
> in T. For any such type T, there must also be a zero element of that
> type t0, such that t1 + t0 -> t1 and t0 + t1 -> t1. + must also be
> associative.
>
> This is violated by both
>
> [1, 2] + [3, 4] -> [1, 2, [3, 4]]
>
> and
>
> 'a' + 3 -> 'd'
Not in C :-)
Cheers,
Ben.
--
http://www.apache-ssl.org/ben.html
"There is no limit to what a man can do or how far he can go if he
doesn't mind who gets the credit." - Robert Woodruff
ApacheCon 2001! http://ApacheCon.com/