[Bug c++/54130] Recognize builtins with bool return type
joseph at codesourcery dot com
gcc-bugzilla@gcc.gnu.org
Tue Jul 31 20:00:00 GMT 2012
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54130
--- Comment #5 from joseph at codesourcery dot com <joseph at codesourcery dot com> 2012-07-31 19:59:50 UTC ---
On Tue, 31 Jul 2012, glisse at gcc dot gnu.org wrote:
> I understand your comments, but I don't know what conclusion to take from them
> about whether gcc should recognize int/bool isnan(double) as a builtin...
Even for C, declaring library functions yourself is very much a legacy
possibility, not good coding practice. GCC matches builtins to declared
functions primarily to optimize code using the standard headers, not code
declaring them directly, and the cases where the type matching is fuzzy
are for the sake of some old system headers.
If your system headers declare isnan with bool return type I advise making
fixincludes fix them. If the declaration doesn't come from system headers
I don't think it's worth GCC optimizing for it.
More information about the Gcc-bugs
mailing list