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: fac41,e01bd86884246855 X-Google-Attributes: gidfac41,public X-Google-Thread: 103376,fb1663c3ca80b502 X-Google-Attributes: gid103376,public From: Greg Subject: Re: Design by Contract (was Re: Interesting thread in comp.lang.eiffel) Date: 2000/07/12 Message-ID: <04377e22.ac0aac49@usw-ex0107-055.remarq.com>#1/1 X-Deja-AN: 645535685 References: <8ipvnj$inc$1@wanadoo.fr> <8j67p8$afd$1@nnrp1.deja.com> <395886DA.CCE008D2@deepthought.com.au> <3958B07B.18A5BB8C@acm.com> <395A0ECA.940560D1@acm.com> <8jd4bb$na7$1@toralf.uib.no> <8jfabb$1d8$1@nnrp1.deja.com> <8jhq0m$30u5$1@toralf.uib.no> <8jt4j7$19hpk$1@ID-9852.news.cis.dfn.de> <3963CDDE.3E8FB644@earthlink.net> <3963DEBF.79C40BF1@eiffel.com> <396502D2.BD8A42E7@earthlink.net> <39654639.B3760EF2@eiffel.com> <85Fa5.11419$7%3.818927@news.flash.net> <01HW.B591811303737A0605DE478C@news.pacbell.net> X-Originating-Host: 208.35.26.248 X-Complaints-To: wrenabuse@remarq.com X-Trace: WReNphoon3 963420617 10.0.2.55 (Wed, 12 Jul 2000 09:50:17 PDT) Organization: http://www.remarq.com: The World's Usenet/Discussions Start Here NNTP-Posting-Date: Wed, 12 Jul 2000 09:50:17 PDT Newsgroups: comp.lang.eiffel,comp.lang.ada X-Wren-Trace: eMjtxcTdmtCbj9HDntua4dfClcnIxomQzsvKi5OMicaUm8abkMaPkpw= Date: 2000-07-12T00:00:00+00:00 List-Id: David Kristola wrote: [snip] > >What kinds of DbC things could i do in Eiffel that i >can't do in Ada with pragma Assert and good typing? > In Eiffel, DbC works with inheritance. So a subclass is bound to the same contract as its parent class automatically. Not being an Ada guru, I'd guess you would have to copy the parent's contract into the child, leading to undesirable duplication. >How can i use the concepts of DbC to make better Ada >code? I don't have a short answer to that. Best I can say is read the relevant chapters in Meyer's "Object Oriented Software Construction" (2nd Ed.) > >Thanks, > >-- >--djk, keeper of arcane lore & trivial fluff >Home: David95036 plus 1 at america on-line >Spam: goto.hades@welovespam.com > > > ----------------------------------------------------------- Got questions? Get answers over the phone at Keen.com. Up to 100 minutes free! http://www.keen.com