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.2 required=5.0 tests=BAYES_00,INVALID_MSGID, PLING_QUERY autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,b87bc683630619fa X-Google-Attributes: gid103376,public From: dewar@cs.nyu.edu (Robert Dewar) Subject: Re: HELP:Declaration in ADA?!! Date: 1996/03/25 Message-ID: #1/1 X-Deja-AN: 144187243 references: <4j65rr$fqg@soleil.uvsq.fr> organization: Courant Institute of Mathematical Sciences newsgroups: comp.lang.ada Date: 1996-03-25T00:00:00+00:00 List-Id: Tuyet asks "DOES SOMEONE KNOW HOW TO DECLARE LONG_INTEGER IN ADA? All the books I've read here does not answer this metaphysical question, they just take it as if everyone should know how to declare it. In a wonderful book, I've seen how to declare LONG_REAL by typing: type LONG_REAL is DIGIT 14; But how to do it for LONG_INTEGER?" I cannot believe there is ANY Ada book that does not answer this simple question, just say type x is range m .. n; where m and n are the bounds you want. If the compiler supports it, that will do it, and if not, you are out of luck. FOr instane, in GNAT, support for at least 64 bits is guaranteed, so type x is range -2**63 .. 2**63-1; will always work (actually in GNAT the type Long_Long_Integer, which is predefined, will always be at least 64 bits).