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=-0.8 required=5.0 tests=BAYES_00,INVALID_DATE autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,a1f67187d079c901 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 1994-10-16 00:29:06 PST Path: bga.com!news.sprintlink.net!howland.reston.ans.net!math.ohio-state.edu!jussieu.fr!univ-lyon1.fr!swidir.switch.ch!epflnews!dinews.epfl.ch!di.epfl.ch!Robb.Nebbe From: Robb.Nebbe@di.epfl.ch (Robb Nebbe) Newsgroups: comp.lang.ada Subject: Re: Is Ada the future? [was: Is C++ the future?] Date: 14 Oct 1994 10:16:41 GMT Organization: Ecole Polytechnique Federale de Lausanne Sender: nebbe@lglsun3.epfl.ch (Robb Nebbe) Distribution: world Message-ID: <1994Oct14.103430@di.epfl.ch> References: <1994Oct13.144031.7290@swlvx2.msd.ray.com> <37k80c$puh@network.ucsd.edu> NNTP-Posting-Host: lglsun3.epfl.ch Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit Date: 1994-10-14T10:16:41+00:00 List-Id: mbk@inls1.ucsd.edu (Matt Kennel) writes: |> |> The core issue: doing this should be possible. (Indeed it |> was hard for me to imagine that it should ever have been |> not possible). |> |> -- Obvious Eiffel construction. |> class ONE is |> a:TWO; |> end; |> |> class TWO is |> b:ONE; |> end; |> To do this ONE and TWO must have an implicit level of indirection. If you use expanded types if Eiffel, which corespond to normal types in Ada, you can't do this. In Ada you can write: type TWO_Implementation; type TWO is access TWO_Implementation; type ONE_Implementation is record a : TWO; end record; type ONE is access ONE_Implementation; type TWO_Implementation is record b : ONE; end record; Which is more or less the same thing as your Eiffel example. The problem is not declaring it, it is distributing it over multiple packages. In Ada the assumption that a type will be handled through a pointer is not valid. - Robb Nebbe