On Sun, Jan 20, 2002 at 06:42:10PM -0800, Max Bian wrote:
> This is interesting.  I wondered why I didn't got kicked by writting
> stuff like this in the early days. I went back and checked. The reason
> was on Sun Sparc machines I used, the int is by default the same as
> long int.

It's funny you should mention the old days.

        Thou shalt foreswear, renounce, and abjure the vile heresy which
        claimeth that "All the world's a VAX", and have no commerce with
        the benighted heathens who cling to this barbarous belief, that
        the days of thy program may be long even though the days of thy
        current machine be short.

        [...]  Beware, in particular, of the subtle and terrible "All
        the world's a 32-bit machine", which is almost true today but
        shall cease to be so before thy resume grows too much longer.

(Well, slightly old days.  Almost 10 years old, and sage advice for
Palm OS programmers today.)

> I am not sure if there is special platform reason on the choice of int
> size, but that's truely a good choice!

Standard C allows a lot of interesting choices to be made.  Many of them
are becoming less likely choices, however, due to the apparent need to
pander to programmers who don't know what they're doing.  For example,
it's unlikely that any new architectures will favour representing null
pointers as anything other than all-bits-zero, not because it's a bad
choice (on the contrary), but because people write non-portable code
because they Just Don't Get It.

    John

-- 
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palmos.com/dev/tech/support/forums/

Reply via email to