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.3 required=5.0 tests=BAYES_00, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Thread: 103376,9ce095aba33fe8d0 X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news3.google.com!news2.volia.net!newsfeed01.sul.t-online.de!t-online.de!newsfeed.vmunix.org!newsfeed.stueberl.de!uucp.gnuu.de!newsfeed.arcor.de!news.arcor.de!not-for-mail From: "Dmitry A. Kazakov" Subject: Re: Negative float problem Newsgroups: comp.lang.ada User-Agent: 40tude_Dialog/2.0.14.1 MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Reply-To: mailbox@dmitry-kazakov.de Organization: cbb software GmbH References: <10mspnley7gzu$.1swtj67sv0ldr$.dlg@40tude.net> Date: Sun, 20 Nov 2005 12:07:20 +0100 Message-ID: NNTP-Posting-Date: 20 Nov 2005 12:07:18 MET NNTP-Posting-Host: 35a1e6e0.newsread2.arcor-online.net X-Trace: DXC=L@T\KEmfbb]\ODPOkW97AZQ5U85hF6f;TjW\KbG]kaMXA@_25la3nbRQ`EBjeV^H5U[6LHn;2LCV^[ On 19 Nov 2005 19:19:32 -0500, Robert A Duff wrote: > No, C++ and Ada are completely different in this regard: In C++, the > literal itself determines its type (the value, plus the presence of > "L"), as you explained above. In Ada, the _context_ determines the type > of the literal. Right. There could be two different ways to describe what's going on. One is to say that all literals overload each other (as if they were functions.) Another is to create a common ancestor type for homographs and overload conversions from them (Universal_Integer, is an example.) Ada uses both and both require the context. -- Regards, Dmitry A. Kazakov http://www.dmitry-kazakov.de