discuss-gnustep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Does GNUstep work on 64-bit platforms?


From: Pete French
Subject: Re: Does GNUstep work on 64-bit platforms?
Date: Sun, 18 Jul 2004 12:55:23 +0100

> long is still 32 bits I believe, but long long is now much faster than it
> used to be.

oops! I forgot all about this - I was going to go find out wasnt I ?

[one quick reboot later]

        char            1
        short           2
        int             4
        long            8
        long long       8
        float           4
        double          8
        long double     16

So the basic change is that long is now the same size as long long, though
an int is still only 32 bits. Interesting that long double has also changed
from 96 bits to 128 bits. The return type of sizeof is now a long not an int
too.

I think the fact that int is not the same as long will turn up a lot
of interesting programming errors, have seen a few in the past on
machines where an int was 16 bits. Trying to explain to a student why
the line "long x = 65535;" results in x being set to -1 whereas
"long x = 65535L;" doesnt for example. Not that any of this necessarily
affects GNUstep of course.

-bat.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]