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.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,e5eb8ca5dcea2827 X-Google-Attributes: gid103376,public From: Fraser Wilson Subject: Re: Ada OO Mechanism Date: 1999/06/03 Message-ID: <928437807.184.56@news.remarQ.com>#1/1 X-Deja-AN: 485375038 References: <7i05aq$rgl$1@news.orbitworld.net> <86k8ttqgia.fsf@ppp-159-70.villette.club-internet.fr> X-Complaints-To: newsabuse@remarQ.com X-Trace: 928437807.184.56 KZBGBQC4S164892E1C qube-02.us-ca.remarq.com Organization: Vegetarian Ada Programmers NNTP-Posting-Date: Thu, 03 Jun 1999 19:23:27 GMT Newsgroups: comp.lang.ada Originator: fraser@titanic Date: 1999-06-03T00:00:00+00:00 List-Id: paene lacrimavi postquam Hyman Rosen scripsit: >You give source code to the compiler, and it gives you either a working >executable, or a set of error messages explaining why it was unable to >do so. Internal phases of the compiler's operation are not of interest >to its user. I disagree with this. One of the things I like about Ada is not having to wait until link time to find out that I forgot to implement a subprogram. It's not just a time factor; the Ada compiler will tell me exactly which package(s) failed to contain the required implementation; all the C or C++ compiler can say is that it didn't find something. It's even worse if, for example, a C or C++ library was written by somebody else, and that person neglected to implement something, but testing never picked it up because it was never called. >You would use a typedef, not a #define. And most templates I've seen >have few parameters. Those with somewhat more tend to default the >later ones so that they may be elided. Really? I can imagine that a large template would be tricky in C++, but it's straightforward in Ada (especially with named argument notation), and surprisingly useful. One particularly handy generic I wrote has 28 parameters ... I'd hate to see that attempted in a less wordy language. Sure, I make new instantiations of it with a bit of cut and paste, but it's really really easy to read, maintain and update. cheers, Fraser. (change i's to y's for my real email address)