From: Dennis Lee Bieber <wlfraed@ix.netcom.com>
Subject: Re: Why does this happen?
Date: Tue, 15 Oct 2002 17:46:40 -0700
Date: 2002-10-16T01:23:30+00:00 [thread overview]
Message-ID: <gtcioa.ut4.ln@ix.netcom.com> (raw)
In-Reply-To: 3DAC92DB.4090307@linux.nu
svesse fed this fish to the penguins on Tuesday 15 October 2002 03:12
pm:
>
> Can someone explain why this would be illegal ?
>
> ---- test.ads ---
> package test is
>
> Type Mtr_Type is array (Positive range <>,
> Positive range <>) of integer;
>
> type T_typ (Ns : Positive) is record
> M : Mtr_Type (1..2, 1 .. ns); -- does not compile
I know Ada is supposed to be case insensitive, but if this is a direct
cut&paste from your file... You have "Ns" in the descriminant (hope I
have the proper term), but "ns" in the array dimension. You /also/ have
spaces surrounding the "..". Neither of these differences show in the
following two lines.
> -- M : Mtr_Type (1..Ns, 1..Ns); -- compiles
> -- M : Mtr_Type (1..Ns, 1..2); -- compiles
The only other idea is that the calculation of offsets for "1..2" can
not be done immediately -- it may be that the parsing requires variable
ranges to be leftmost in the subscript order.
--
> ============================================================== <
> 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/ <
next prev parent reply other threads:[~2002-10-16 0:46 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-10-15 22:12 Why does this happen? svesse
2002-10-16 0:46 ` Dennis Lee Bieber [this message]
2002-10-16 2:25 ` tmoran
2002-10-16 6:02 ` Anders Wirzenius
2002-10-16 7:32 ` tmoran
2002-10-16 13:44 ` Frank J. Lhota
2002-10-16 5:36 ` Simon Wright
2002-10-16 15:53 ` Jerry van Dijk
2002-10-17 9:50 ` Colin Paul Gloster
2002-10-17 12:08 ` Jerry van Dijk
2002-10-16 19:56 ` Gautier
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox