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.9 required=5.0 tests=BAYES_00 autolearn=unavailable autolearn_force=no version=3.4.4 Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!news.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail From: Georg Bauhaus Newsgroups: comp.lang.ada Subject: Re: Dynamic type system for Ada Date: Wed, 25 Jan 2017 08:38:48 -0000 (UTC) Organization: A noiseless patient Spider Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Injection-Date: Wed, 25 Jan 2017 08:38:48 -0000 (UTC) Injection-Info: mx02.eternal-september.org; posting-host="3ea35c4d9a894dd3d65c2e45116b10d2"; logging-data="19996"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18PK9MoKJ/ZbNC8VstP3xuvUqIQxn/SYms=" User-Agent: NewsTap/5.1.8 (iPhone/iPod Touch) Cancel-Lock: sha1:zXSx1jjbwFZR+ppaKU4zGxpJFSg= sha1:NqAc0zA2VV1iBxmvWboXbl2lv1Q= Xref: news.eternal-september.org comp.lang.ada:33155 Date: 2017-01-25T08:38:48+00:00 List-Id: Randy Brukardt wrote: > if one organized the hierarchy similar to > the chart in 3.2(12) > [http://www.ada-auth.org/standards/2xrm/html/RM-3-2.html#p12], you could > define shared operations at the appropriate levels to have some use beyond > just plain storage. (For instance, all of the numeric types would have math > this way.) Objective-C class clusters seem to be of a similar kind, e.g. NSNumber. The objects can then also participate in anything based on NSObject, basically, such as being sent in a local or remote notification or being part of a persistent object graph. But then, Objective-C does not have so much in terms of Ada generics, insofar as these permit specifying private formal types, derived or not, to have just the operations that are needed in instances. > I do wonder how useful such a hierarchy would be, but I suppose someone > would have to build it to find out.