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,FREEMAIL_FROM autolearn=unavailable autolearn_force=no version=3.4.4 X-Received: by 10.42.118.200 with SMTP id y8mr46411673icq.4.1412129580824; Tue, 30 Sep 2014 19:13:00 -0700 (PDT) X-Received: by 10.182.70.39 with SMTP id j7mr709215obu.1.1412129580662; Tue, 30 Sep 2014 19:13:00 -0700 (PDT) Path: border2.nntp.dca1.giganews.com!nntp.giganews.com!usenet.blueworldhosting.com!feeder01.blueworldhosting.com!news.glorb.com!a13no6333345igq.0!news-out.google.com!rp1ni8527igb.0!nntp.google.com!a13no6333338igq.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Newsgroups: comp.lang.ada Date: Tue, 30 Sep 2014 19:13:00 -0700 (PDT) In-Reply-To: Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=24.36.114.177; posting-account=Lb5doAoAAAAWHET3z2_nBVbFSXaZQG1V NNTP-Posting-Host: 24.36.114.177 References: User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: <3190e4ed-b687-43b6-bc20-a4545e2073e4@googlegroups.com> Subject: Re: casting types From: Stribor40 Injection-Date: Wed, 01 Oct 2014 02:13:00 +0000 Content-Type: text/plain; charset=ISO-8859-1 Xref: number.nntp.giganews.com comp.lang.ada:189263 Date: 2014-09-30T19:13:00-07:00 List-Id: On Tuesday, 30 September 2014 22:06:58 UTC-4, Jeffrey Carter wrote: > On 09/30/2014 06:49 PM, Stribor40 wrote: > > > > > > How would I cast var1 to become 123 but still be able to subtract it from var1 and keep float type? > > > > You can't, since there is no casting in Ada. However, you might find the > > 'Truncation attribute function useful. > > > > http://www.adaic.org/resources/add_content/standards/12rm/html/RM-A-5-3.html > > > > -- > > Jeff Carter > > "Nobody expects the Spanish Inquisition!" > > Monty Python's Flying Circus > > 22 Would you mind showing an example please...