-
Notifications
You must be signed in to change notification settings - Fork 146
Use more stdint.h types #674
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
I guess because of all the LONG <-> pointer conversions in the code, LONG should really be the same as intptr_t (unless the conversions are fixed), which makes compilation on 32-bit systems broken if WORD/LONG are 32/64 bits. |
8fababe to
3ff6564
Compare
This helps to reduce diagnostics reported by -Wconversion.
Also, drop declarations of some non-existing functions, and change a few (but not all) of the functions that always succeed to void.
|
OK, so this is the current proposed set of changes to use stdint.h more. This is what was discussed in @670, except I've decided not to remove ILP32 support for not, because it turned out to be very helpful in catching WORD vs int distinction in the code (something I'd wish the compiler would do for us, but it wouldn't). Instead I've slightly simplified the detection of 32-bit platforms using stdint.h alone, and updated all the code that did |
|
This cleanup looks good to me. Any comments from anyone else? |
|
If I'm not mistaken, |
Use
stdint.hinstead of INT{16,32,64}. Make WORD always int32_t, and drop ILP32 support. As discussed in #670. ILP32 deprecation was previously suggested in #624.