comp.lang.ada
 help / color / mirror / Atom feed
From: tmoran@acm.org
Subject: Re: Question: Combination of Access and Constraining
Date: Thu, 20 Feb 2003 09:00:48 GMT
Date: 2003-02-20T09:00:48+00:00	[thread overview]
Message-ID: <4P05a.187861$be.178144@rwcrnsc53> (raw)
In-Reply-To: 1d13e1b4.0302200006.70207b86@posting.google.com

>   type TpCon is new Tp(1..1);
>
> expected type: Tp_Access defined at ...
> found type TpCon defined at ...
Ada is serious about types.  Try
  Arr : aliased Tp := (1 .. 1 =>True);

I presume there's a good reason you go to all this trouble with
access types, instead of just saying
  function Fn (Arg : Tp) return Natural;
  Arr : Tp(1 .. 1);
begin
  Arr(1) := True;
  Res := Fn (Arr);



  reply	other threads:[~2003-02-20  9:00 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-02-20  8:06 Question: Combination of Access and Constraining Papandopulo
2003-02-20  9:00 ` tmoran [this message]
2003-02-20  9:29 ` Dmitry A. Kazakov
2003-02-20 15:20   ` Papandopulo
2003-02-20 16:20     ` Dmitry A. Kazakov
2003-02-20 17:58     ` Jeffrey Carter
2003-02-20 20:35       ` Yuri
2003-02-21  1:21         ` Jeffrey Carter
2003-02-21 22:53           ` Yuri
2003-02-23 12:34             ` Simon Wright
2003-02-23 17:50               ` Jeffrey Carter
2003-02-23 17:55               ` John R. Strohm
2003-02-23 17:48             ` John R. Strohm
2003-02-20 13:12 ` David C. Hoos, Sr.
2003-02-20 15:00 ` Matthew Heaney
  -- strict thread matches above, loose matches on Subject: below --
2003-02-20  9:46 Grein, Christoph
replies disabled

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