msg224528 - (view) |
Author: STINNER Victor (vstinner) *  |
Date: 2014-08-02 00:14 |
The issue #22110 enabled more compiler warnings. Attached patch tries to fix most of them on Linux. |
|
|
msg224529 - (view) |
Author: STINNER Victor (vstinner) *  |
Date: 2014-08-02 00:15 |
clinic.patch: modify clinic.py to generate "return_value == (type)-1" instead of "return_value == -1" to avoid a warning if return_value is unsigned. |
|
|
msg224534 - (view) |
Author: Serhiy Storchaka (serhiy.storchaka) *  |
Date: 2014-08-02 04:58 |
I think this should be done only for unsigned integer types. Otherwise it just dirty sources and can hide actual bugs. |
|
|
msg224540 - (view) |
Author: STINNER Victor (vstinner) *  |
Date: 2014-08-02 08:04 |
It would be better to only modify clinic for unsigned types, but how do you check if a type is signed or not? |
|
|
msg224543 - (view) |
Author: Serhiy Storchaka (serhiy.storchaka) *  |
Date: 2014-08-02 08:56 |
Either override render() for unsigned type converters, or add new converter attribute (in additional to "type", "cast", "conversion_fn", etc). |
|
|
msg224555 - (view) |
Author: STINNER Victor (vstinner) *  |
Date: 2014-08-02 12:10 |
Hum, I forgot the attach the most important patch: fix_warnings.patch. |
|
|
msg224811 - (view) |
Author: Larry Hastings (larry) *  |
Date: 2014-08-05 06:20 |
The title for this bug was almost offensively generic; it was hard to find in my email. If this new one is inaccurate, fix it--but please pick something more specific. Attached is a patch for the "_return_value == -1" behavior for unsigned. |
|
|
msg224813 - (view) |
Author: Serhiy Storchaka (serhiy.storchaka) *  |
Date: 2014-08-05 08:08 |
larry.fix.unsigned.int.return.-1.converter.cast.1.txt LGTM. Victor, looks as you should open new issue for fix_warnings.patch. This is large patch and requires long time for careful review and may be discussion. |
|
|
msg224816 - (view) |
Author: Roundup Robot (python-dev)  |
Date: 2014-08-05 09:55 |
New changeset 9c949e0115e2 by Larry Hastings in branch 'default': Issue #22120: For functions using an unsigned integer return converter, http://hg.python.org/cpython/rev/9c949e0115e2 |
|
|
msg224817 - (view) |
Author: Larry Hastings (larry) *  |
Date: 2014-08-05 09:57 |
Fixed and closed. I'm assuming Victor will break the other patch out into its own issue. Since IIUC there's no code in 3.4 that uses an unsigned integer return converter, I'm not backporting the fix. |
|
|
msg224925 - (view) |
Author: STINNER Victor (vstinner) *  |
Date: 2014-08-06 10:38 |
Since my argument clinic patch hijacked this issue, I created a new one for fix_warnings.patch: issue #22156. |
|
|