-
Notifications
You must be signed in to change notification settings - Fork 602
Prefer %ll over %L for formatting long long ints #20137
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
Configure used to try %L, %q, and then %ll in this order to find the modifier for formatting 64-bit integers on 32-bit machines, but %L for integer conversions seems to be a non-standard GNU extension. Now it will try %ll before %q, %L to prioritize %ll which is standardized by C99.
|
Doesnt this need @Tux ? |
|
Yes, it does. I am trying real hard to catch up currently |
|
I'd like to see test-runs on AIX, HP-UX and Solaris. |
|
Otherwise I think this change looks good! Thank you |
|
@Tux, does that mean we can merge this PR? |
|
HP-UX and AIX are back on-line. Anyone has time to check them? |
|
I tested this on aix with -DUSE_MORE_BITS, and unfortunately all the formats for 32-bit items look like this: |
|
I have no idea what the final verdict is. Can I merge this now? |
|
It doesn't work on aix. @t-a-k please look at this |
|
Sorry for delayed response, but I don't have an access to AIX hosts so a bit more information will be helpful. Does the test pass if configured without |
|
I tried again on AIX, and it worked! I don't know what went wrong before. Sorry. I think this should be merged in 5.39.1 |
I'm relieved to hear that. Anyway this PR should only affect formats for 64-bit integers. If any 32-bit formats such as |
Configure used to try
%L,%q, and then%llin this order to find the modifier for formatting 64-bit integers on 32-bit machines, but%Lfor integer conversions (such as in%Ld) seems to be a non-standard GNU extension.I think it will better to try
%llbefore%qand%L, as%llis standardized by C99.