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,604e0f87aa06eab6 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2003-03-18 02:37:13 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!bloom-beacon.mit.edu!nycmny1-snh1.gtei.net!nycmny1-snf1.gtei.net!news.gtei.net!colt.net!peernews3.colt.net!news0.de.colt.net!news-fra1.dfn.de!news-koe1.dfn.de!RRZ.Uni-Koeln.DE!uni-duisburg.de!not-for-mail From: Georg Bauhaus Newsgroups: comp.lang.ada Subject: Re: Imitation is the sincerest form of flattery Date: Tue, 18 Mar 2003 10:37:12 +0000 (UTC) Organization: GMUGHDU Message-ID: References: <1047665830.579605@master.nyc.kbcfp.com> NNTP-Posting-Host: d2-hrz.uni-duisburg.de X-Trace: a1-hrz.uni-duisburg.de 1047983832 19634 134.91.1.15 (18 Mar 2003 10:37:12 GMT) X-Complaints-To: usenet@news.uni-duisburg.de NNTP-Posting-Date: Tue, 18 Mar 2003 10:37:12 +0000 (UTC) User-Agent: tin/1.5.8-20010221 ("Blue Water") (UNIX) (HP-UX/B.11.00 (9000/831)) Xref: archiver1.google.com comp.lang.ada:35443 Date: 2003-03-18T10:37:12+00:00 List-Id: Hyman Rosen wrote: : He's listed as a "member of the expert group". The Java generics : are particularly bad. While that presentation likes to make the : usual lies about C++ templates, what they don't tell you is that : in the Java generics the type parameters can't be fundamental : types, only Object-derived ones (look at all their examples), and : that you can't overload on generics: : class Joe { : void f(List l) { } : void f(List l) { } : } Yes and no. Perhaps it's the bad habit of many a C++ program to not give names to types, that is use abstraction, and instead use "in place generics", that leads to this expectation? class LI extends LinkedList {} class LB extends LinkedList {} class Joe { void f(LI l) { } void f(LB l) { } } (Not that easy exposing just the List interface, which I've just learned is easily accomplished in Eiffel, using a "join feature".) I'd guess that Betrand Meyer will tell you that OO is in many cases about *avoiding* overloading. class Joe ... { void f(List l) {} } class Jane ... { void f(List l) {} } As for fundamental types, in a true OO language there shouldn't be non-OO types in the first place, so some true OO-languages don't have them :-) I'm not saying that any language should be a true OO-language and nothing more.