Re: Q: void* vs. unsigned long

H. Peter Anvin (hpa@transmeta.com)
16 Feb 1999 05:44:30 GMT


Followup to: <36C900C8.EB3C534F@quark.vpplus.com>
By author: Brian Gerst <bgerst@quark.vpplus.com>
In newsgroup: linux.dev.kernel
>
> H. Peter Anvin wrote:
> > Actually, it will. sizeof(unsigned long) == sizeof(void *) == 8 on
> > 64-bit architectures.
>
> I thought it was int that changed with the word size of the
> architecture, not long. Most C books I've seen said long is always 32
> bits regardless of the word size. Regardless, if the value represents a
> pointer, then it should be declared as such - for the sake of clarity if
> nothing else.
>

That's bogus; most likely they have only worked on Micro$oft systems.

-hpa

-- 
"Linux is a very complete and sophisticated operating system.  There
are, and will be, large numbers of applications available for it."
    -- Paul Maritz, Group Vice President for Platforms And Applications,
       Microsoft Corporation [Reference at: http://www.kernel.org/~hpa/ms.html]

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/