From: Jim Rogers <jimmaureenrogers@worldnet.att.net>
Subject: Re: Ada access vs C/C++ pointers and references
Date: Thu, 19 Aug 2004 00:29:07 GMT
Date: 2004-08-19T00:29:07+00:00 [thread overview]
Message-ID: <Xns9549BC0AE8D46jimmaureenrogers@127.0.0.1> (raw)
In-Reply-To: b47de02.0408181427.25d82fe1@posting.google.com
duggar@mit.edu (Keith H Duggar) wrote in news:b47de02.0408181427.25d82fe1
@posting.google.com:
> I'm simply asking four things.
>
> First, is it correct to say that Ada access types ore more
> similar to C++ references (T&) than they are to C/C++
> pointers (T*) ?
Not really. C++ references are always implemented as const
pointers. Ada access types are assignable, just like C/C++
pointers.
>
> Second, does Ada provide any facilities for direct and raw
> memory access by memory address and pointer arithmetic?
Yes, but not directly through access types. The package
System.Storage_Elements provides the ability to perform
integer arithmetic on addresses.
Note that the package contains functions for converting between
addresses and Integer_Address. This allows Ada to work correctly
on systems without linear addressing schemes, such as the old
next prev parent reply other threads:[~2004-08-19 0:29 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-08-18 22:27 Ada access vs C/C++ pointers and references Keith H Duggar
2004-08-19 0:21 ` Nick Roberts
2004-08-19 11:42 ` Marin David Condic
2004-08-19 0:29 ` Jim Rogers [this message]
2004-08-19 5:19 ` Ludovic Brenta
2004-08-19 6:21 ` Martin Dowie
2004-08-19 11:55 ` Marin David Condic
2004-08-19 18:01 ` Ludovic Brenta
2004-08-19 7:19 ` j
2004-08-19 7:42 ` Martin Dowie
2004-08-19 12:03 ` Marin David Condic
2004-08-19 7:59 ` Ole-Hjalmar Kristensen
2004-08-19 15:33 ` Keith H Duggar
2004-08-19 21:32 ` Ludovic Brenta
2004-08-19 22:18 ` Hyman Rosen
2004-08-20 7:52 ` Ole-Hjalmar Kristensen
2004-08-19 8:11 ` Dmitry A. Kazakov
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox