[Mono-devel-list] Prevalence of pointer-integral-pointer castingin mono?
bernard at ugs.com
Tue Aug 3 11:39:12 EDT 2004
I am not really sure what the questions are leading to.
But I don't believe the current CLI spec supports 128-bit pointers
at all. And the doc for IntPtr states:
The IntPtr type is designed to be an integer whose size is
platform-specific. That is, an instance of this type is expected to be
32-bits on 32-bit hardware and operating systems, and 64-bits on
64-bit hardware and operating systems.
and does not mention any other possibilities.
----- Original Message -----
From: "Peter Colson" <pcolson at connexus.net.au>
To: <mono-devel-list at lists.ximian.com>
Sent: Monday, August 02, 2004 7:23 PM
Subject: [Mono-devel-list] Prevalence of pointer-integral-pointer castingin
> (Hope this appears at the right point in the list...)
> Responding to Paolo...
> OK, let's accept that the Mono runtime code is not particularly subject
> to the problem of casting a pointer to an integral type and back,
> expecting it to still be useable as a pointer.
> Where does that leave us with respect to the IntPtr and UIntPtr types in
> C# and the requirement for these types to be able to hold a pointer and
> allow those contents to be treated as a pointer?
> If the platform concerned has 128-bit pointers and no native integral
> type to hold a pointer, is the ability to support (U)IntPtrs prevented?
> Furthermore, am I right in saying that any .Net-style runtime operating
> on a platform is going to have recourse to using unsafe calls (at least
> internally) requiring the use of (U)IntPtr's, even if C# code written on
> that platform makes no use of unsafe code?
> Peter Colson,
> Carringbush Software.
> Mono-devel-list mailing list
> Mono-devel-list at lists.ximian.com
More information about the Mono-devel-list