comp.lang.ada
 help / color / mirror / Atom feed
From: AdaMagica <christoph.grein@eurocopter.com>
Subject: Re: Array initialization in SPARK
Date: Sat, 30 Oct 2010 01:10:12 -0700 (PDT)
Date: 2010-10-30T01:10:12-07:00	[thread overview]
Message-ID: <0570b344-ba2b-4de5-9c5a-a71d61c73bfd@l20g2000yqm.googlegroups.com> (raw)
In-Reply-To: a3dd40b0-1d0c-4292-b982-b4c62a0dd017@u17g2000yqi.googlegroups.com

On 30 Okt., 03:04, Phil Clayton <phil.clay...@lineone.net> wrote:
> ...  We
> could then write something like:
>
>   Out_Matrix :=
>      Matrix'(for I in Natural range Out_Matrix'Range(1) =>
>                (for J in Natural range Out_Matrix'Range(2) =>
>                   In_Matrix(J, I)));

But we would need an assertion that 'Range(1) equals 'Range(2), else
we would get Constraint_Error. (Equal lengths would not suffice - no
sliding there.)



  reply	other threads:[~2010-10-30  8:10 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-10-28 10:13 Array initialization in SPARK Peter C. Chapin
2010-10-28 12:47 ` Phil Thornley
2010-10-28 14:51   ` Peter C. Chapin
2010-10-28 15:23     ` Peter C. Chapin
2010-10-28 16:26       ` Alexander Senier
2010-10-28 16:38         ` Phil Thornley
2010-10-30  1:04           ` Phil Clayton
2010-10-30  8:10             ` AdaMagica [this message]
2010-10-30 13:11               ` Phil Clayton
  -- strict thread matches above, loose matches on Subject: below --
2009-06-15 12:01 xorque
2009-06-15 12:10 ` xorque
replies disabled

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