This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/26099] support for type traits is not available
- From: "pcarlini at suse dot de" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 27 Jan 2008 13:34:48 -0000
- Subject: [Bug c++/26099] support for type traits is not available
- References: <bug-26099-3238@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #14 from pcarlini at suse dot de 2008-01-27 13:34 -------
(In reply to comment #13)
> If a function isn't marked nothrow and the function can be overridden by a
> shared library (that is, it doesn't bind locally), the compiler cannot derive
> such property from its body.
Thanks for the details.
> (I didn't look at the tests, but usually marking the affected functions
> nothrow or making them bind locally works around this problem).
Well, the functions in those specific tests aren't marked no throw on purpose
(we do have other tests for the no throw variants), because I was exactly
testing that in some specific cases the C++ front-end is able to figure out by
itself that the function doesn't really throw. All in all I'm now thinking that
it's good to have such tests, we should only conditionalize the result of the
tests on -fpic/PIC, I suppose we do have a macro for that?!?
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26099