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 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,6828bb58accfa664 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2002-11-10 16:12:50 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!cyclone.bc.net!snoopy.risq.qc.ca!newsfeed.news2me.com!newsfeed2.earthlink.net!newsfeed.earthlink.net!stamper.news.pas.earthlink.net!stamper.news.atl.earthlink.net!harp.news.atl.earthlink.net!beastie.ix.netcom.com!nobody From: Dennis Lee Bieber Newsgroups: comp.lang.ada Subject: Re: Conditional types? Date: Sun, 10 Nov 2002 15:04:46 -0800 Organization: >> Leaf-Eating Penguins? << Message-ID: References: NNTP-Posting-Host: d1.56.00.f2 Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7Bit X-Server-Date: 11 Nov 2002 00:12:50 GMT User-Agent: KNode/0.6.1 X-noarchive: yes Xref: archiver1.google.com comp.lang.ada:30695 Date: 2002-11-11T00:12:50+00:00 List-Id: Caffeine Junky fed this fish to the penguins on Sunday 10 November 2002 12:34 pm: > > You're recieving data through a function call or a procedure of some > sort, but the source for some reason does not indicate explicitly what > type of data it is. However, since you do have some limited knowledge > of the system you can safely assume it's passing either a float, an > integer, or an unsigned 32 bit integer. Is there a way do this in Ada I know of NO language that can identify what 32 random bits of data is supposed to represent. It could be 4 8-bit characters, 2 16-bit characters, or even a memory address. 0x80 (just to keep the numbers small) could be signed -128, unsigned +123 -- without some additional information the bit pattern tells one nothing. You /might/ be able to identify that /some/ patterns are not /valid/ floats, but that is the limit. -- > ============================================================== < > wlfraed@ix.netcom.com | Wulfraed Dennis Lee Bieber KD6MOG < > wulfraed@dm.net | Bestiaria Support Staff < > ============================================================== < > Bestiaria Home Page: http://www.beastie.dm.net/ < > Home Page: http://www.dm.net/~wulfraed/ <