Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!sun-barr!apple!snorkelwacker.mit.edu!bloom-beacon!eru!hagbard!sunic!mcsun!hp4nl!tnoibbc!pw From: pw@tnoibbc.UUCP (Peter Willems) Newsgroups: comp.lang.eiffel Subject: repeating assertions ? Keywords: assertions Message-ID: <2190@tnoibbc.UUCP> Date: 30 Nov 90 15:00:10 GMT Lines: 41 Consider the next example consisting of two classes A and B. B inherits from A and uses A's Create feature: class A feature identifier: STRING; Create (s: STRING) is require s_exists: not s.Void do identifier := s ensure identifier = s end; -- Create end -- class A class B inherit A rename Create as a_Create feature Create (s: STRING) is do a_Create (s) end; -- Create end -- class B Question: should class B repeat the assertions specified with the Create feature in class A ? If not than essential class interface information will be omitted in the documentation provided by flat and short. However, repeating this information seems contradictory with the object-oriented rule of reusability. Any suggestions ? -- Peter Willems : TNO - IBBC INTERNET : pw@tnoibbc : PO-box 49 DOMAIN : pw@ibbc.tno.nl : 2600 AA Delft FAX : +31 15 843990 : the Netherlands VOICE : +31 15 842032