64 bit coding

bill davidsen davidsen at tmr.com
Wed Apr 25 19:47:16 UTC 2001


In article <ylitjvbyim.fsf at windlord.stanford.edu>,
Russ Allbery  <rra at stanford.edu> wrote:

| I think that if a compiler is warning about this sort of thing, there's
| something wrong with the compiler.  What is it complaining about, that
| you're assigning a smaller data type to a larger data type?  That's
| allowed.

Well, so is a warning, that's what casts are all about.

| I actually doubt that INN *is* making many assumptions like that, as INN
| has worked fine on Tru64 for quite some time.  I think you've got an
| overactive compiler that's jumping at shadows, from the examples you've
| given so far.  But I'd be happy to see more specific details....

I agree with all of that, but I'd bet it assumes that int means 32 bits.
The way to test this is to compile with option "-Dint=short" and see if
it works. I realize that INN is unlikely to have to compile and run on a
16 bit system, but it certainly is an issue if you want to pick the odd
nit or two.

Since 64 bits is more a problem than 16, I don't see this on my plate,
just commenting on the actual portability. I believe I did get Bnews
running on a 16 bit PDP{something}, once when I was young and foolish.

-- 
bill davidsen <davidsen at tmr.com>
  CTO, TMR Associates, Inc
Doing interesting things with little computers since 1979.


More information about the inn-workers mailing list