From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,f039470e8f537101 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2003-07-29 13:00:27 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!logbridge.uoregon.edu!arclight.uoregon.edu!enews.sgi.com!news.xtra.co.nz!53ab2750!not-for-mail Newsgroups: comp.lang.ada Subject: Re: Non-philosophical definition of Eiffel? From: Berend de Boer Message-ID: User-Agent: Gnus/5.090014 (Oort Gnus v0.14) Emacs/21.2 (i386-msvc-nt5.0.2195) References: <1058968422.225561@master.nyc.kbcfp.com> <3F200AD0.94F79098@adaworks.com> <7u9Ua.13412$634.10307@nwrdny03.gnilink.net> <3F215120.1040706@attbi.com> <1059151910.357790@master.nyc.kbcfp.com> <1059416297.548253@master.nyc.kbcfp.com> Cancel-Lock: sha1:2ggTauho9ae98VRR9fqnHBnw3zc= MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Wed, 30 Jul 2003 07:58:40 +1200 NNTP-Posting-Host: 219.88.64.124 X-Complaints-To: newsadmin@xtra.co.nz X-Trace: news.xtra.co.nz 1059508826 219.88.64.124 (Wed, 30 Jul 2003 08:00:26 NZST) NNTP-Posting-Date: Wed, 30 Jul 2003 08:00:26 NZST Organization: Xtra Xref: archiver1.google.com comp.lang.ada:40963 Date: 2003-07-30T07:58:40+12:00 List-Id: >>>>> "Hyman" == Hyman Rosen writes: Hyman> For those unfamiliar with the concept, Eiffel allows a Hyman> derived class to override an inherited method with a method Hyman> whiach takes a more restricted argument type. This Hyman> obviously causes huge correctness issues, since at any call Hyman> using a base object you may be committing a type violation Hyman> that you are not even aware of! The Eiffel people have Hyman> spent years trying to figure out ways around the problem Hyman> while still keeping the original design. Well: 1. No one needs to use the facility if you don't want it. 2. Contravariance in arguments is not of much practical use. 3. Covariance does not only occur in arguments but in other cases as well (generic types). 4. Covariance is of practical use. I think it's a good decision to spend time trying to solve it. But if it can't be done, it should be removed. There is a too long paper on this subject: http://www.stud.tu-ilmenau.de/~robertw/headings.cgi/~robertw/eiffel/covariance3.htm (just read appendix B) It seems that the Eiffel world is moving to accept the fact that the issue must be solved now and that perhaps contravariance must go in cases where the compiler cannot verify it is used correctly. There also is a much more elaborate attempt to solve it: http://www.inf.ethz.ch/~meyer/ongoing/covariance/recast.pdf But it seems fairly complex. But for people wanting an introduction to the issue, this last paper is the one to read. -- Regards, Berend. (-: