PYLONG_BITS_IN_DIGIT is misconfigured on g++
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Python |
Fix Released
|
Unknown
|
|||
python2.7 (Ubuntu) |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
gcc and g++ interprets pyport.h in different way.
```
(system) inada-n@oldbench:~$ cat longbits.c
#include <Python.h>
#include <longintrepr.h>
int main() {
}
(system) inada-n@oldbench:~$ gcc longbits.c -I /usr/include/
(system) inada-n@oldbench:~$ ./a.out
digit bits = 30
sizeof(digit) = 4
(system) inada-n@oldbench:~$ g++ longbits.c -I /usr/include/
(system) inada-n@oldbench:~$ ./a.out
digit bits = 15
sizeof(digit) = 2
```
This breaks some extension modules. For example, see https:/
Please backport this bugfix.
https:/
Changed in python: | |
status: | Unknown → Fix Released |
according to the upstream issue this is fixed since 2012.