[Mono-devel-list] Prevalence of pointer-integral-pointer castingin mono?
pcolson at connexus.net.au
Wed Aug 4 01:30:17 EDT 2004
On Wed, 2004-08-04 at 01:39, Bernie Solomon wrote:
> I am not really sure what the questions are leading to.
Hopefully I explain in my reply to Jonathan. This exercise has been a
bit of thinking on the run from my perspective, with issues cropping up
along the way.
> 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.
> Bernie Solomon
> ----- 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?
> > Regards,
> > Peter Colson,
> > Carringbush Software.
> > _______________________________________________
> > Mono-devel-list mailing list
> > Mono-devel-list at lists.ximian.com
> > http://lists.ximian.com/mailman/listinfo/mono-devel-list
More information about the Mono-devel-list