This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: long double causes compiler warnings
Type: Stage:
Components: Interpreter Core Versions:
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: Nosy List: jackjansen, jyasskin, tim.peters
Priority: normal Keywords:

Created on 2002-03-04 12:02 by jackjansen, last changed 2022-04-10 16:05 by admin. This issue is now closed.

Messages (4)
msg9497 - (view) Author: Jack Jansen (jackjansen) * (Python committer) Date: 2002-03-04 12:02
The 2.44 changes to objimpl.h, especially the "long double" bit, causes numerous warnings on Mac OS X (and possible on other gcc-based platforms). Maybe the suggestion of adding the -Wno-long-double option should be taken, maybe something else should be done (adding a config-based define for the type with the biggest alignment requirement?).

/Users/jack/src/python/Include/objimpl.h:275: warning: use of `long double' type; its size may change in a future release
/Users/jack/src/python/Include/objimpl.h:275: warning: (Long double usage is reported only once for each file.
/Users/jack/src/python/Include/objimpl.h:275: warning: To disable this warning, use -Wno-long-double.)
msg9498 - (view) Author: Tim Peters (tim.peters) * (Python committer) Date: 2002-03-10 01:27
Logged In: YES 
user_id=31435

Well, since 2.44 consisted entirely of adding the 5-
character string "long " to objimpl.h, I think we can be 
sure that was the cause <wink>.

But "long double" a standard C type, and I don't think a 
compiler has any business warning about using a standard C 
type in a vanilla way.  Someone who has access to this 
compiler should fix it, if they care enough to do so.  
That's not me on either count, so I'm unassigning this 
report.
msg9499 - (view) Author: Jack Jansen (jackjansen) * (Python committer) Date: 2002-03-12 15:28
Logged In: YES 
user_id=45365

Added a -Wno-long-double to the CFLAGS (configure.in 1.295, configure 1.285). It turns out MacOSX gcc gives the warning because Mac compilers have traditionally used either 64, 96 or 128 bits for long double, and Apple hasn't decided yet what the final size will be for OSX gcc (and when they change this that will change the compiler ABI).
msg63650 - (view) Author: Jeffrey Yasskin (jyasskin) * (Python committer) Date: 2008-03-17 15:10
I reverted this in r61436 to fix issue 1779871. The long double is still
around, but the gcc bundled with OS X 10.4 doesn't warn about it anymore.
History
Date User Action Args
2022-04-10 16:05:03adminsetgithub: 36195
2008-03-17 15:10:12jyasskinsetnosy: + jyasskin
messages: + msg63650
2002-03-04 12:02:31jackjansencreate