comp.lang.ada
 help / color / mirror / Atom feed
From: robert_dewar@my-dejanews.com
Subject: Re: How do I get this to work??
Date: 1999/01/06
Date: 1999-01-06T00:00:00+00:00	[thread overview]
Message-ID: <76uvjt$o0f$1@nnrp1.dejanews.com> (raw)
In-Reply-To: 36926c54.2583014@news.pacbell.net

In article <36926c54.2583014@news.pacbell.net>,
  tmoran@bix.com (Tom Moran) wrote:
> NO.  'address is non-portable.  For instance, one of the
> compilers I use regularly uses the full Intel
> segment:offset form, all 32 bits, for 'address, vs 32
> bits with (Win32's) implied segment for 'access.

First, I assume you mean full 48 bits for the
segment:offset form, since that is what it is in 32-bit
mode, and surely you are talking about 32-bit mode here.

If so, that is an extraordinarily bad choice for a compiler
to make. Why? Because there is loads of legacy code around
that assumes that an Address value can be passed to C as
a pointer. A compiler that does not allow this usage is in
my opinion badly flawed if you want to interface to C using
it.

Also, what makes you think that an access type is any more
portable? There is NO reason to think this.

The RM provides no guarantee at all that the representation
of either access types or addresses corresponds to what a
C pointer looks like.

Any reasonable compiler will make both access types in at
least the cases that make sense to C (e.g. simple types or
constrained arrays, or non-variant records), and addresses
be identical to C pointers.

But if what you say is true, then there are unreasonable
compilers around. If so, then all bets are off regarding
portability of *either* access types *or* addresses across
the C boundary.

-----------== Posted via Deja News, The Discussion Network ==----------
http://www.dejanews.com/       Search, Read, Discuss, or Start Your Own    




  reply	other threads:[~1999-01-06  0:00 UTC|newest]

Thread overview: 55+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1999-01-04  0:00 How do I get this to work?? Chris Warwick
1999-01-05  0:00 ` Tom Moran
1999-01-05  0:00 ` Chris Warwick
1999-01-05  0:00   ` Stephen Leake
1999-01-05  0:00     ` Tom Moran
1999-01-06  0:00       ` robert_dewar [this message]
1999-01-06  0:00         ` Tom Moran
1999-01-07  0:00           ` robert_dewar
1999-01-07  0:00             ` Tom Moran
1999-01-10  0:00               ` robert_dewar
1999-01-06  0:00         ` Larry Kilgallen
1999-01-06  0:00           ` Tom Moran
1999-01-06  0:00         ` Tom Moran
1999-01-07  0:00           ` robert_dewar
1999-01-07  0:00             ` Tom Moran
1999-01-10  0:00               ` robert_dewar
1999-01-10  0:00                 ` Tom Moran
1999-01-10  0:00                   ` robert_dewar
1999-01-10  0:00                   ` robert_dewar
1999-01-10  0:00                     ` Pat Rogers
1999-01-10  0:00                     ` Tom Moran
1999-01-06  0:00     ` Chris Warwick
1999-01-06  0:00       ` Tom Moran
1999-01-07  0:00       ` robert_dewar
1999-01-09  0:00         ` Chris Warwick
1999-01-09  0:00           ` Simon Wright
1999-01-10  0:00             ` robert_dewar
1999-01-11  0:00               ` Simon Wright
1999-01-16  0:00               ` Chris Warwick
1999-01-16  0:00                 ` Simon Wright
1999-01-16  0:00                 ` robert_dewar
1999-01-18  0:00                   ` Chris Warwick
1999-01-18  0:00                     ` Matthew Heaney
1999-01-16  0:00                 ` Matthew Heaney
1999-01-16  0:00                   ` robert_dewar
1999-01-18  0:00                   ` Chris Warwick
1999-01-18  0:00                     ` robert_dewar
1999-01-18  0:00                       ` Tucker Taft
1999-01-19  0:00                         ` Chris Warwick
1999-01-19  0:00                           ` Tom Moran
1999-01-19  0:00                           ` robert_dewar
1999-01-20  0:00                             ` Jeff Carter
1999-01-20  0:00                               ` robert_dewar
1999-01-21  0:00                                 ` Chris Warwick
1999-01-19  0:00                           ` Stephen Leake
1999-01-18  0:00                       ` dennison
1999-01-18  0:00                     ` dennison
1999-01-18  0:00                     ` Matthew Heaney
1999-01-09  0:00           ` Brian Rogoff
1999-01-10  0:00             ` Matthew Heaney
1999-01-07  0:00       ` Stephen Leake
1999-01-08  0:00         ` Simon Wright
1999-01-06  0:00     ` robert_dewar
1999-01-06  0:00   ` Simon Wright
1999-01-22  0:00   ` Nick Roberts
replies disabled

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