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.1 required=5.0 tests=BAYES_00, PP_MIME_FAKE_ASCII_TEXT autolearn=no autolearn_force=no version=3.4.4 X-Google-Thread: 103376,d5b211b0c1ffcf3e X-Google-NewGroupId: yes X-Google-Attributes: gida07f3367d7,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII Received: by 10.68.238.65 with SMTP id vi1mr336708pbc.7.1340300376038; Thu, 21 Jun 2012 10:39:36 -0700 (PDT) MIME-Version: 1.0 Path: l9ni3955pbj.0!nntp.google.com!news2.google.com!volia.net!news2.volia.net!feed-A.news.volia.net!news.ecp.fr!news.jacob-sparre.dk!munin.jacob-sparre.dk!pnx.dk!.POSTED!not-for-mail From: "Randy Brukardt" Newsgroups: comp.lang.ada Subject: Re: Practicalities of Ada for app development Date: Thu, 21 Jun 2012 12:39:30 -0500 Organization: Jacob Sparre Andersen Research & Innovation Message-ID: References: <1c82b5mc3waww.1t6q6vj61u36u.dlg@40tude.net> <42a87cf3ce9bfd6054f78b2b5b356301@dizum.com> <3e8c1c78-31b0-462e-8341-6d661fbc8378@googlegroups.com> NNTP-Posting-Host: static-69-95-181-76.mad.choiceone.net X-Trace: munin.nbi.dk 1340300374 28666 69.95.181.76 (21 Jun 2012 17:39:34 GMT) X-Complaints-To: news@jacob-sparre.dk NNTP-Posting-Date: Thu, 21 Jun 2012 17:39:34 +0000 (UTC) X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2900.5931 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.6157 X-RFC2646: Format=Flowed; Response Date: 2012-06-21T12:39:30-05:00 List-Id: "Yannick Duch�ne (Hibou57)" wrote in message news:op.wfrdhbh1ule2fv@douda-yannick... >Le Mon, 11 Jun 2012 20:29:47 +0200, Adam Beneschan a >�crit: >> IIRC, some people have proposed adding unsigned integer types to the >> language; they've argued that modular types aren't good enough for some >> purposes. But the idea was turned down. > >Why? Why was it turned down? To much complication for to little gain, I think. There is a lot of overhead to having a new kind of type in the language (not only the type declaration, but also with generic formals, in Text_IO, etc.). Janus/Ada has always supported unsigned representations of "signed" integer types (we did that in Ada 83, before there were modular types). I think most compilers do that, in fact. But as Adam says, you can force the signed representation in some cases, so for: type T is range 0 .. 2**32-1; you have to support a signed version, which is easy to get -- just use T'Base. And for the largest integer representation supported by the compiler (32 or 64 or whatever), that's impossible, so Janus/Ada has to reject the above declaration. (We don't have general 64-bit integer support.) Randy.