comp.lang.ada
 help / color / mirror / Atom feed
From: dewar@cs.nyu.edu (Robert Dewar)
Subject: Re: access aliased obstacle
Date: 1996/07/09
Date: 1996-07-09T00:00:00+00:00	[thread overview]
Message-ID: <dewar.836958957@schonberg> (raw)
In-Reply-To: ws920ilyp94.fsf@schonberg.cs.nyu.edu


Laurent said

"   The idea is that there are stored somewhere, "in the record" is an
unfortunate wording ;-). BTW, is there any compiler that use the
alternative you proposed ? How to get the following right without
storing "in the record"?"

I don't think any compilers do this, but it is perfectly viable to treat
discriminants like subscripts for arrays, which certainly need not be
stored with the arrays (think of the fat pointer implemenation in
GNAT for arrays, it could easily adapt to variant records, with 
separate pointers to the discriminants and data). 

When we were designing the info systems annex, we considered using
a variant record design for decimal numbers with the precision being
a diiscriminant, but that is only viable if you do this separate
allocation, and we did not feel that would be easy for compilers
to do!





  reply	other threads:[~1996-07-09  0:00 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1996-07-09  0:00 access aliased obstacle tmoran
1996-07-09  0:00 ` Laurent Guerby
1996-07-09  0:00   ` Robert Dewar
1996-07-09  0:00 ` Laurent Guerby
1996-07-09  0:00   ` Robert Dewar [this message]
1996-07-10  0:00     ` Robert A Duff
1996-07-09  0:00 ` Robert Dewar
  -- strict thread matches above, loose matches on Subject: below --
1996-07-04  0:00 tmoran
1996-07-04  0:00 ` Robert Dewar
1996-07-06  0:00 ` Laurent Guerby
1996-07-07  0:00 ` Robert A Duff
replies disabled

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