|
|
Warp wrote:
> So the implicit conversion rules of C for signed and unsigned integers
> are weird? Care to suggest better conversion rules?
No, they make perfect sense, when you consider that they're two
different ranges of values fit into the same number of bits. I'm merely
pointing out that the errors you describe comes from treating "int"s as
"integers". There's no such thing as an "unsigned integer", only an
"unsigned int". It was a nit, nothing more. :-)
I.e., the problem isn't the conversion rules, but the fact that people
code in C without constantly keeping in mind the limitations caused by
the low-level nature of the values and the lack of error checking.
--
Darren New / San Diego, CA, USA (PST)
Remember the good old days, when we
used to complain about cryptography
being export-restricted?
Post a reply to this message
|
|