From: "Jeffrey R. Carter" <spam.jrcarter.not@spam.not.acm.org>
Subject: Re: How to get a 2D arrays range?
Date: Sat, 21 Nov 2015 22:02:50 -0700
Date: 2015-11-21T22:02:50-07:00 [thread overview]
Message-ID: <n2ri5d$tnq$1@dont-email.me> (raw)
In-Reply-To: <75e0a3fe-a4fc-43e5-a773-06d7bb553b38@googlegroups.com>
On 11/21/2015 08:31 PM, John Smith wrote:
>
> Of the nested for-loop, where I explicitly call out 1 .. 10, I'd like to specify
> the range more dynamically. How can I do this?
In ARM K.2, Language-Defined Attributes, we find
185/1
A'Range
For a prefix A that is of an array type (after any implicit dereference), or
denotes a constrained array subtype:
186
A'Range is equivalent to the range A'First .. A'Last, except that the prefix A
is only evaluated once. See 3.6.2.
and
189/1
A'Range(N)
For a prefix A that is of an array type (after any implicit dereference), or
denotes a constrained array subtype:
190
A'Range(N) is equivalent to the range A'First(N) .. A'Last(N), except that the
prefix A is only evaluated once. See 3.6.2.
http://www.adaic.org/resources/add_content/standards/12rm/html/RM-K-2.html
--
Jeff Carter
"If you think you got a nasty taunting this time,
you ain't heard nothing yet!"
Monty Python and the Holy Grail
23
next prev parent reply other threads:[~2015-11-22 5:02 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-11-22 3:31 How to get a 2D arrays range? John Smith
2015-11-22 5:02 ` Jeffrey R. Carter [this message]
2015-11-22 7:09 ` Niklas Holsti
2015-11-22 8:58 ` Simon Wright
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox