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: 109fba,b87849933931bc93 X-Google-Attributes: gid109fba,public X-Google-Thread: fac41,b87849933931bc93 X-Google-Attributes: gidfac41,public X-Google-Thread: 1108a1,b87849933931bc93 X-Google-Attributes: gid1108a1,public X-Google-Thread: 103376,b87849933931bc93 X-Google-Attributes: gid103376,public X-Google-Thread: 114809,b87849933931bc93 X-Google-Attributes: gid114809,public From: dewar@merv.cs.nyu.edu (Robert Dewar) Subject: Re: OO, C++, and something much better! Date: 1997/01/25 Message-ID: #1/1 X-Deja-AN: 212274077 references: <5bphq4$5js@mulga.cs.mu.OZ.AU> <32E05FAF.47BA@concentric.net> <5buodl$bci@boursy.news.erols.com> <32E2FEC7.2F7B@concentric.net> <6PE5zLpF3RB@herold.franken.de> <32E57E2B.6CB7@epix.net> <32E57FBC.2325@epix.net> <5c4ita$3qs@mulga.cs.mu.OZ.AU> <32E6797A.6E21@parcplace.com> <32e87d25.0@194.131.7.3> organization: New York University newsgroups: comp.lang.eiffel,comp.lang.ada,comp.lang.c++,comp.lang.smalltalk,comp.object Date: 1997-01-25T00:00:00+00:00 List-Id: "Perhaps an even more amusing trial, to embarass those used to languages that rely soley on fixed size integer and floating point arithmetic, is to use Smalltalk to calculate the largest known prime number. To do so, evaluate:" Incidentally I don't know why anyone should be embarrassed by having integer types with limits. There are many advantages, both in efficiency and from the point of view of enforcing invariants in having types with well defined ranges. An interesting P.S. for the Ada folks reading this (like so many messages today, this thread is cross-posted to a whole bunch of language groups -- we really need a separate group for this rambling stuff on languages -- an inordinate amount of which is rambling by people who clearly know very little about language design -- anyway back to Ada. In Ada 95, the type Integer'Base is an unconstrained type. An implementation is allowed, BUT NOT REQUIRED, to limit the range of values of this type that it will handle, so it is quite permissible to use multiple precision for this type. This would be nicer than introducing a new type, since Ada, like nearly all other languages, has trouble introducing general literals for new types, so if you use Integer'Base this way, you also get arbitrary precision literals.