Related articles |
---|
[6 earlier articles] |
Re: Looking for volunteers for XL kaz@kylheku.com (Kaz Kylheku) (2011-11-28) |
Re: Looking for volunteers for XL tdk@thelbane.com (Timothy Knox) (2011-11-27) |
Re: Looking for volunteers for XL bc@freeuk.com (BartC) (2011-11-28) |
Re: Looking for volunteers for XL gah@ugcs.caltech.edu (glen herrmannsfeldt) (2011-11-28) |
Re: Looking for volunteers for XL christophe@taodyne.com (Christophe de Dinechin) (2011-11-28) |
Re: Looking for volunteers for XL gah@ugcs.caltech.edu (glen herrmannsfeldt) (2011-11-29) |
Re: Looking for volunteers for XL jussi.santti@ard.fi (ardjussi) (2011-11-30) |
Re: Looking for volunteers for XL kaz@kylheku.com (Kaz Kylheku) (2011-12-01) |
Re: Looking for volunteers for XL kaz@kylheku.com (Kaz Kylheku) (2011-12-01) |
Re: Looking for volunteers for XL blog@rivadpm.com (Alex McDonald) (2011-12-01) |
Re: overloading, was Looking for volunteers for XL gah@ugcs.caltech.edu (glen herrmannsfeldt) (2011-12-02) |
Re: Looking for volunteers for XL jgk@panix.com (2011-12-13) |
Re: Looking for volunteers for XL thomas.mertes@gmx.at (tm) (2012-01-03) |
From: | ardjussi <jussi.santti@ard.fi> |
Newsgroups: | comp.compilers |
Date: | Wed, 30 Nov 2011 13:16:54 -0800 (PST) |
Organization: | Compilers Central |
References: | 11-11-048 11-11-053 11-11-054 11-11-058 11-11-060 11-11-067 |
Keywords: | types, design |
Posted-Date: | 30 Nov 2011 21:56:38 EST |
On 29 marras, 00:12, Christophe de Dinechin <christo...@taodyne.com>
wrote:
>
> > The other kind of extensibility I know about is operator overloading,
> > where the problems are well-known; the expression A+B could
> > conceivably mean anything, instead of being restricted to a small set
> > of predefined types.
>
> This argument was made a long time ago byBertrand Meyerin a very
> articulate article, see
> http://se.ethz.ch/~meyer/publications/joop/overloading.pdf.
>
> While the article is very well written, I totally disagree with Meyer
> on this (even though I respect him a lot as a language designer). Why?
> Because I can't even think of using a programming language where I
> need to write "1 + 2" for integer addition, and something different
> like "1.3 +. 4.2" for floating-point addition.
This is not the case with Eiffel. The addition operator for both
integer and floating is "+". This is not a case of operator
overloading in pure object oriented setting of Eiffel, since the
operator appears in two different classes: integer and floating. An
example of overloading would be "+" appearing twice with different
signatures in the integer class.
br Jussi
Return to the
comp.compilers page.
Search the
comp.compilers archives again.