comp.lang.ada
 help / color / mirror / Atom feed
From: "R. Tim Coslet" <R_Tim_Coslet@pacbell.net>
Subject: Re: Behavior of Stream Attributes On Access Types.
Date: Tue, 11 Jun 2002 05:33:03 GMT
Date: 2002-06-11T05:33:03+00:00	[thread overview]
Message-ID: <B92AD893.4284%R_Tim_Coslet@pacbell.net> (raw)
In-Reply-To: ae2v7f$r12$1@nh.pace.co.uk

As I understand it, the LRM simply leaves it "implementation defined".

I don't expect the value to be of any use...

I always write custom 'Read and 'Write functions for access types
specifically designed to instead read or write the "subtree" of the data
structure the access points to, instead of the value.

Of course this only works for types used to define simple "linear" and
"tree" shaped data structures. It would get much more involved for the
"general" case.

-- 
        R. Tim Coslet
        r_tim_coslet@pacbell.net

Technology, n. Domesticated natural phenomena.


> From: "Marin David Condic" <dont.bother.mcondic.auntie.spam@[acm.org>
> Organization: Posted on a server owned by Pace Micro Technology plc
> Newsgroups: comp.lang.ada
> Date: Mon, 10 Jun 2002 15:38:20 -0400
> Subject: Behavior of Stream Attributes On Access Types.
> 
> I'm checking section 13.13.2 of the ARM to discover the default behavior of
> the Stream 'Read, 'Write, 'Input and 'Output when they encounter an access
> type. I'm not finding any clear indication of what gets put to the stream -
> although there is a mention in paragraph 35 of raising Constraint_Error on
> input if the value is not of its subtype. Can someone clarify the behavior?
> 
> My inclination is to think that the sensible thing would be to call the
> 'Read or 'Write for the thing pointed to by the access type, but this has
> implications for dynamically allocated objects. Will it write/read a
> (totally useless) access value?
> 
> MDC
> --
> Marin David Condic
> Senior Software Engineer
> Pace Micro Technology Americas    www.pacemicro.com
> Enabling the digital revolution
> e-Mail:    marin.condic@pacemicro.com
> 
> 
> 




  reply	other threads:[~2002-06-11  5:33 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-06-10 19:38 Behavior of Stream Attributes On Access Types Marin David Condic
2002-06-11  5:33 ` R. Tim Coslet [this message]
2002-06-11 14:15   ` Marin David Condic
2002-06-11 13:47 ` Ted Dennison
2002-06-11 14:27   ` Marin David Condic
2002-06-11 14:37     ` Marin David Condic
2002-06-12 14:19       ` David C. Hoos
2002-06-12 15:18         ` Marin David Condic
2002-06-13  3:00           ` David C. Hoos, Sr.
2002-06-14 18:27           ` Simon Wright
2002-06-14 18:53             ` Marin David Condic
2002-06-15 14:56               ` Simon Wright
2002-06-16  2:27                 ` Randy Brukardt
2002-06-17 14:31                   ` Marin David Condic
2002-06-18 19:30                     ` Randy Brukardt
2002-06-12 19:39       ` Randy Brukardt
2002-06-12 13:31     ` Ted Dennison
2002-06-11 21:56   ` Randy Brukardt
2002-06-12  3:44 ` David C. Hoos, Sr.
replies disabled

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