diff options
author | Paolo Carlini <paolo.carlini@oracle.com> | 2009-07-12 23:25:29 +0000 |
---|---|---|
committer | Paolo Carlini <paolo@gcc.gnu.org> | 2009-07-12 23:25:29 +0000 |
commit | 026ec377e996447a3472cf6304d612864353ef0d (patch) | |
tree | dc8805e3fbeb23c8ab7d257f998fcfda6358fa6a /libstdc++-v3 | |
parent | b9c6b842a913ca6b98f12c8291a40a6cc90b41bc (diff) | |
download | gcc-026ec377e996447a3472cf6304d612864353ef0d.zip gcc-026ec377e996447a3472cf6304d612864353ef0d.tar.gz gcc-026ec377e996447a3472cf6304d612864353ef0d.tar.bz2 |
re PR c++/36628 ([c++0x] incorrect decltype() handling of conditional operator)
2009-07-12 Paolo Carlini <paolo.carlini@oracle.com>
* include/std/type_traits (common_type): Remove workaround for
PR36628, now fixed.
From-SVN: r149537
Diffstat (limited to 'libstdc++-v3')
-rw-r--r-- | libstdc++-v3/ChangeLog | 5 | ||||
-rw-r--r-- | libstdc++-v3/include/std/type_traits | 7 |
2 files changed, 6 insertions, 6 deletions
diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog index f9cac8c..97a165d 100644 --- a/libstdc++-v3/ChangeLog +++ b/libstdc++-v3/ChangeLog @@ -1,3 +1,8 @@ +2009-07-12 Paolo Carlini <paolo.carlini@oracle.com> + + * include/std/type_traits (common_type): Remove workaround for + PR36628, now fixed. + 2009-07-11 Richard Sandiford <rdsandiford@googlemail.com> PR testsuite/40699 diff --git a/libstdc++-v3/include/std/type_traits b/libstdc++-v3/include/std/type_traits index ce9ee1b..94c40df 100644 --- a/libstdc++-v3/include/std/type_traits +++ b/libstdc++-v3/include/std/type_traits @@ -580,13 +580,8 @@ namespace std static _Tp&& __t(); static _Up&& __u(); - // HACK: Prevents optimization of ?: in the decltype - // expression when the condition is the literal, "true". - // See, PR36628. - static bool __true_or_false(); - public: - typedef decltype(__true_or_false() ? __t() : __u()) type; + typedef decltype(true ? __t() : __u()) type; }; template<typename _Tp, typename _Up, typename... _Vp> |