[issue37812] Make implicit returns explicit in longobject.c (in CHECK_SMALL_INT)

STINNER Victor report at bugs.python.org
Tue Sep 17 18:26:14 EDT 2019


STINNER Victor <vstinner at python.org> added the comment:

Sadly, GH-15710 was merged without mentioning the bpo-37812 (this issue) in the final commit message :-(

commit 6b519985d23bd0f0bd072b5d5d5f2c60a81a19f2
Author: animalize <animalize at users.noreply.github.com>
Date:   Fri Sep 6 14:00:56 2019 +0800

    replace inline function `is_small_int` with a macro version (GH-15710)


This second change introduced a regression: bpo-38205 "Python no longer compiles without small integer singletons".

I don't understand the whole issue. A first change converted a macro to a static inline function. The second change converted the static inline fnuction to a macro... but the overall change introduced a regression. Why not reverting the first change instead of pushing a new change?

Morever, if using a static inline function is causing issues, it would be nice to add a comment to explain why, so the issue will be avoided in the future.

----------
nosy: +vstinner
resolution: fixed -> 
status: closed -> open

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue37812>
_______________________________________


More information about the Python-bugs-list mailing list