Skip to content
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

bpo-1635741: Port _stat module to multiphase initialization #19798

Merged
merged 5 commits into from
Apr 29, 2020

Conversation

corona10
Copy link
Member

@corona10 corona10 commented Apr 29, 2020

Modules/_stat.c Outdated Show resolved Hide resolved
@corona10 corona10 requested a review from vstinner April 29, 2020 17:23
@corona10
Copy link
Member Author

@vstinner Please take a look

Modules/_stat.c Outdated Show resolved Hide resolved
Modules/_stat.c Show resolved Hide resolved
Modules/_stat.c Outdated Show resolved Hide resolved
Modules/_stat.c Outdated Show resolved Hide resolved
Copy link
Member

@vstinner vstinner left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks for the updates!

@corona10 corona10 merged commit 84724dd into python:master Apr 29, 2020
@corona10 corona10 deleted the bpo-1635741-stat branch April 29, 2020 18:20
@vstinner
Copy link
Member

The new code emits a compiler warning:

./Modules/_stat.c: In function ‘stat_exec’:
./Modules/_stat.c:566:23: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
     for (int i = 0; i < Py_ARRAY_LENGTH(st_constants); i++) {
                       ^

Py_ARRAY_LENGTH() should be casted to int.

cc @corona10

@vstinner
Copy link
Member

Py_ARRAY_LENGTH() should be casted to int.

After I saw the warning 5 times in a row, I decided to propose a PR for the trivial fix :-)
#19822

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants