comp.lang.ada
 help / color / mirror / Atom feed
From: "Ed Falis" <falis@verizon.net>
Subject: Re: How to extract range from array
Date: Fri, 17 Mar 2006 12:29:56 GMT
Date: 2006-03-17T12:29:56+00:00	[thread overview]
Message-ID: <op.s6j4zsgc5afhvo@dogen> (raw)
In-Reply-To: dve67s$omt$1@sunnews.cern.ch

On Fri, 17 Mar 2006 06:23:40 -0500, Maciej Sobczak <no.spam@no.spam.com>  
wrote:

> type My_Array is array(1..10) of Integer;
>    type My_Range is ???;

type My_Range is new Integer range My_Array'Range;

However, if you intend to use My_Range to index an object of type  
My_Array, the following is more useful because it won't require a type  
conversion to integer:

subtype My_Range is Integer range My_Array'Range;



  reply	other threads:[~2006-03-17 12:29 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-03-17 11:23 How to extract range from array Maciej Sobczak
2006-03-17 12:29 ` Ed Falis [this message]
2006-03-17 15:12 ` Martin Krischik
2006-03-20 10:04   ` Maciej Sobczak
2006-03-20 13:14   ` Maciej Sobczak
2006-03-20 13:58     ` Ed Falis
2006-03-20 14:20     ` Dmitry A. Kazakov
2006-03-20 15:31     ` Robert A Duff
2006-03-20 19:01     ` Martin Krischik
2006-03-20 20:20       ` Georg Bauhaus
2006-03-20 21:51       ` Jeffrey R. Carter
2006-03-21 19:12         ` Martin Krischik
replies disabled

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