comp.lang.ada
 help / color / mirror / Atom feed
From: dewar@schonberg.cs.nyu.edu (Robert Dewar)
Subject: Re: Rules for Representation of Subtypes
Date: 1996/09/28
Date: 1996-09-28T00:00:00+00:00	[thread overview]
Message-ID: <dewar.843920516@schonberg> (raw)



Bob Duff said

"But this is all very obscure.  If you're interfacing to hardware, or to
C, or to something else where the interface is a low-level binary
interface, the best thing to do is make the types match the hardware, or
the C, or whatever it is.  Don't use constraints on the Ada side of the
interface, just because the logical properties would warrant a
constraint.
"

If you are using GNAT, you need not worry about this. We found that so
many users were depending on objects of a subtype being the same as
objects of the base type that it was essential to do this. If you use
a compiler that does NOT have this convention with existing Ada 83
code, our experience is that you will likely run into troubles.

At the very least, I think that a compiler should regard a subtype
object as having  the same size as the base type for convention C.

i.e. the implementatiojn advice in the RM to squeeze things down is
actively undesirable for pragma foreign conventions where this would
not be done by the foriegn language.






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

Thread overview: 61+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1996-09-28  0:00 Robert Dewar [this message]
1996-09-29  0:00 ` Rules for Representation of Subtypes Robert A Duff
1996-09-29  0:00   ` Matthew Heaney
  -- strict thread matches above, loose matches on Subject: below --
1996-10-10  0:00 W. Wesley Groleau (Wes)
1996-10-10  0:00 ` Robert Dewar
1996-10-11  0:00 ` Ken Garlington
1996-10-03  0:00 Franco Mazzanti
1996-10-03  0:00 ` Robert A Duff
1996-10-02  0:00 Franco Mazzanti
1996-10-03  0:00 ` Robert A Duff
1996-09-28  0:00 Robert Dewar
1996-09-29  0:00 ` Robert A Duff
1996-09-29  0:00   ` Matthew Heaney
1996-09-29  0:00   ` Robert Dewar
1996-09-30  0:00     ` Art Schwarz
1996-09-30  0:00       ` Robert A Duff
1996-10-01  0:00       ` Larry Kilgallen
1996-10-01  0:00         ` Brian R. Hanson
1996-10-01  0:00         ` Robert A Duff
1996-09-28  0:00 Robert Dewar
1996-09-30  0:00 ` Keith Thompson
1996-09-22  0:00 Matthew Heaney
1996-09-23  0:00 ` Robert A Duff
1996-09-24  0:00   ` Matthew Heaney
1996-09-26  0:00     ` Robert A Duff
1996-09-26  0:00       ` Larry Kilgallen
1996-09-27  0:00         ` Robert A Duff
1996-09-27  0:00           ` Mark A Biggar
1996-09-30  0:00             ` Robert A Duff
1996-10-01  0:00               ` Larry Kilgallen
1996-10-01  0:00                 ` Robert A Duff
1996-10-01  0:00                 ` Samuel Tardieu
1996-10-01  0:00                   ` Ken Garlington
1996-09-28  0:00           ` Larry Kilgallen
1996-09-29  0:00             ` Robert A Duff
1996-09-29  0:00               ` Matthew Heaney
1996-09-30  0:00                 ` Robert Dewar
1996-09-30  0:00                   ` Matthew Heaney
1996-09-30  0:00                 ` Robert A Duff
1996-09-29  0:00               ` Larry Kilgallen
1996-09-29  0:00                 ` Matthew Heaney
1996-09-30  0:00                 ` Robert A Duff
1996-10-01  0:00                   ` Ken Garlington
1996-10-02  0:00                     ` Robert A Duff
1996-10-02  0:00                       ` Ken Garlington
1996-10-06  0:00                   ` Robert Dewar
1996-10-03  0:00             ` Robert Dewar
1996-09-27  0:00       ` Matthew Heaney
1996-09-27  0:00         ` Robert A Duff
1996-09-23  0:00 ` David C. Hoos, Sr.
1996-09-23  0:00   ` Samuel T. Harris
1996-09-26  0:00     ` David C. Hoos, Sr.
1996-09-23  0:00   ` Robert A Duff
1996-09-24  0:00   ` Robert Dewar
1996-09-24  0:00   ` Robert Dewar
1996-09-26  0:00     ` Keith Thompson
1996-09-26  0:00       ` Matthew Heaney
1996-09-27  0:00         ` Robert Dewar
1996-09-27  0:00         ` Robert A Duff
1996-09-27  0:00           ` Robert Dewar
1996-09-27  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