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=-2.9 required=5.0 tests=BAYES_00,MAILING_LIST_MULTI autolearn=unavailable autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,b6e97963d32ee242 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2003-05-23 10:57:46 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!newsfeed.icl.net!newsfeed.fjserv.net!proxad.net!freenix!enst.fr!not-for-mail From: Lionel.DRAGHI@fr.thalesgroup.com Newsgroups: comp.lang.ada Subject: RE: The old "Object.Method" syntax debate Date: Fri, 23 May 2003 19:59:32 +0200 Organization: ENST, France Message-ID: NNTP-Posting-Host: marvin.enst.fr Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" X-Trace: avanie.enst.fr 1053712665 56057 137.194.161.2 (23 May 2003 17:57:45 GMT) X-Complaints-To: usenet@enst.fr NNTP-Posting-Date: Fri, 23 May 2003 17:57:45 +0000 (UTC) To: comp.lang.ada@ada.eu.org Return-Path: X-Mailer: Internet Mail Service (5.5.2653.19) X-BeenThere: comp.lang.ada@ada.eu.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: comp.lang.ada mail to news gateway List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Xref: archiver1.google.com comp.lang.ada:37705 Date: 2003-05-23T19:59:32+02:00 | -----Message d'origine----- | De: john@nospam.demon.co.uk [mailto:john@nospam.demon.co.uk] ... | You could have something like: | | tagged package X is | a : integer; | b : float; | | procedure method; | end X; | | So 'a' and 'b' would be object attributes and 'method' would be an | object method. This sort of package would essentially define a single | tagged type without all of the record definition and controlling | parameters etc. | | Further you could use: | | tagged package Y is new X with | c : some_enumerated_type; | end Y; | etc.. | I find this pretty elegant, although using the "package" keyword leads to the class/module confusion that Ada currently avoid. And removing "package" brings us not so far from Steve proposal, isn't it? -- Lionel Draghi.