comp.lang.ada
 help / color / mirror / Atom feed
From: James Rogers <jimmaureenrogers@att.net>
Subject: Re: Type detection
Date: Sat, 01 May 2004 05:01:32 GMT
Date: 2004-05-01T05:01:32+00:00	[thread overview]
Message-ID: <Xns94DBE9DC62033jimmaureenrogers@204.127.36.1> (raw)
In-Reply-To: QoydncxqQenacg_d4p2dnA@comcast.com

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 961 bytes --]

"Robert I. Eachus" <rieachus@comcast.net> wrote in
news:QoydncxqQenacg_d4p2dnA@comcast.com: 

> Bj�rn Persson wrote:
> 
>> For the special case of distinguishing integer types from enumeration
>> types, I've been thinking of using something like this...
> 
> I extended the idea a little further, but there is still some work to 
> do.  A character type is an enumeration type where at least one of the
> enumeration values is a character literal.  So the test for
> enumeration types could be extended with a loop.

The problem with all these tests is an assumption that there is one
integer type. None of these tests can distinguish from various 
integer types. They are only approximately good for determining 
whether a type is an enumeration type or has a value within the
range of Standard.Integer. In Ada this is not even close to type
identification. This is merely distinguishing between enumeration
and non-enumeration discrete types.

Jim Rogers



  reply	other threads:[~2004-05-01  5:01 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-04-30 12:17 Newbie Ada Axel Druesnes
2004-04-30 12:22 ` Preben Randhol
2004-04-30 13:20 ` Hyman Rosen
2004-04-30 13:54 ` Type detection Björn Persson
2004-04-30 15:04   ` Marius Amado Alves
2004-05-01  0:28   ` Robert I. Eachus
2004-05-01  5:01     ` James Rogers [this message]
2004-05-01  7:12       ` Robert I. Eachus
2004-05-01 12:43       ` Björn Persson
2004-05-01 12:42     ` Björn Persson
2004-04-30 14:49 ` Newbie Ada Lutz Donnerhacke
2004-05-02 13:33 ` Stephen Leake
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox