comp.lang.ada
 help / color / mirror / Atom feed
From: Dmitry A. Kazakov <mailbox@dmitry-kazakov.de>
Subject: Re: Problem With Self-Referential Access-to-Subprogram Type
Date: Wed, 05 Nov 2003 09:31:53 +0100
Date: 2003-11-05T09:31:53+01:00	[thread overview]
Message-ID: <20chqvglnrae8njr0011cfg3a8hc82je7m@4ax.com> (raw)
In-Reply-To: mailman.270.1067957851.25614.comp.lang.ada@ada-france.org

On Tue, 04 Nov 2003 14:52:33 +0000, Marius Amado Alves
<amado.alves@netcabo.pt> wrote:

>On Tue, 2003-11-04 at 14:24, Dmitry A.Kazakov wrote:
>> Yes, there is a difference. Technically, for an out parameter the
>> compiler should still know the object constraints.
>
>Only at runtime. Consider Ada.Text_IO.Get (Item : out String). What
>constraints is the compiler knowing here?

It knows that there are bounds which cannot be changed. If Item were
of String (1..5) the compiler would probably choose another way of
parameter passing than for String (<>) with the consequence that the
stack frame would be different. I suppose, that one could allow
premature use of types. Even as evil as:

type X;
type Y is record
   What_Is_That : X;
end Y;

but the price would be too high. We will have 10,000 pages of ARM to
describe it and a pair or two halting problems to solve. (:-))

---
Regards,
Dmitry Kazakov
www.dmitry-kazakov.de



  reply	other threads:[~2003-11-05  8:31 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-11-03 16:58 Problem With Self-Referential Access-to-Subprogram Type Tad Ashlock
2003-11-04 10:04 ` Dmitry A. Kazakov
2003-11-04 13:52   ` Tad Ashlock
2003-11-04 14:24     ` Dmitry A. Kazakov
2003-11-04 14:52       ` Marius Amado Alves
2003-11-05  8:31         ` Dmitry A. Kazakov [this message]
2003-11-05 11:27           ` Marius Amado Alves
2003-11-05 13:33             ` Dmitry A. Kazakov
2003-11-05 14:02               ` Marius Amado Alves
2003-11-05 17:49             ` Adam Beneschan
2003-11-05 18:55               ` Marius Amado Alves
2003-11-05 22:54                 ` Tad Ashlock
2003-11-06 17:45                   ` Warren W. Gay VE3WWG
  -- strict thread matches above, loose matches on Subject: below --
2003-11-03 17:32 amado.alves
2003-11-04 14:02 ` Tad Ashlock
replies disabled

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