lkml.org 
[lkml]   [1999]   [Feb]   [16]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Q: void* vs. unsigned long

On 16-Feb-99 Brian Gerst wrote:
> 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.

Throw them away.

long is defined to be the longest integer type, long enough to hold any other
integer value (which is why "long long" is inherently broken). Casting between
void * and long is never portable, but a compiler implementer would be a fool
to break it.

J

-
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/

\
 
 \ /
  Last update: 2005-03-22 13:50    [W:0.089 / U:0.108 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site