diff options
author | Paolo Carlini <pcarlini@suse.de> | 2007-04-30 10:27:31 +0000 |
---|---|---|
committer | Paolo Carlini <paolo@gcc.gnu.org> | 2007-04-30 10:27:31 +0000 |
commit | 6a7508ec12df68051366e3305c02c5940db2df75 (patch) | |
tree | fb000f48068b4855be27a3bdec36af58f70bf558 /libstdc++-v3 | |
parent | 4be242bb3b2fe1c9231df01e67f4d6dc2e10c183 (diff) | |
download | gcc-6a7508ec12df68051366e3305c02c5940db2df75.zip gcc-6a7508ec12df68051366e3305c02c5940db2df75.tar.gz gcc-6a7508ec12df68051366e3305c02c5940db2df75.tar.bz2 |
type_traits (is_pod): Use __is_pod.
2007-04-30 Paolo Carlini <pcarlini@suse.de>
* include/tr1/type_traits (is_pod): Use __is_pod.
* testsuite/tr1/4_metaprogramming/type_properties/
has_trivial_destructor/has_trivial_destructor.cc: Adjust.
* testsuite/tr1/4_metaprogramming/type_properties/
has_nothrow_constructor/has_nothrow_constructor.cc: Likewise.
* testsuite/tr1/4_metaprogramming/type_properties/
has_trivial_constructor/has_trivial_constructor.cc: Likewise.
* testsuite/tr1/4_metaprogramming/type_properties/
is_pod/is_pod.cc: Likewise.
From-SVN: r124294
Diffstat (limited to 'libstdc++-v3')
6 files changed, 21 insertions, 19 deletions
diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog index 4943213..b99cbe7 100644 --- a/libstdc++-v3/ChangeLog +++ b/libstdc++-v3/ChangeLog @@ -1,3 +1,15 @@ +2007-04-30 Paolo Carlini <pcarlini@suse.de> + + * include/tr1/type_traits (is_pod): Use __is_pod. + * testsuite/tr1/4_metaprogramming/type_properties/ + has_trivial_destructor/has_trivial_destructor.cc: Adjust. + * testsuite/tr1/4_metaprogramming/type_properties/ + has_nothrow_constructor/has_nothrow_constructor.cc: Likewise. + * testsuite/tr1/4_metaprogramming/type_properties/ + has_trivial_constructor/has_trivial_constructor.cc: Likewise. + * testsuite/tr1/4_metaprogramming/type_properties/ + is_pod/is_pod.cc: Likewise. + 2007-04-29 Paolo Carlini <pcarlini@suse.de> * include/bits/localefwd.h: Remove redundant inline qualifiers. diff --git a/libstdc++-v3/include/tr1/type_traits b/libstdc++-v3/include/tr1/type_traits index 8645427..c824ef7 100644 --- a/libstdc++-v3/include/tr1/type_traits +++ b/libstdc++-v3/include/tr1/type_traits @@ -249,9 +249,7 @@ _GLIBCXX_BEGIN_NAMESPACE(_GLIBCXX_TR1) template<typename _Tp> struct is_pod - : public integral_constant<bool, (is_void<_Tp>::value - || is_scalar<typename - remove_all_extents<_Tp>::type>::value)> + : public integral_constant<bool, __is_pod(_Tp) || is_void<_Tp>::value> { }; template<typename _Tp> diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_nothrow_constructor/has_nothrow_constructor.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_nothrow_constructor/has_nothrow_constructor.cc index 8296867..02743a1 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_nothrow_constructor/has_nothrow_constructor.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_nothrow_constructor/has_nothrow_constructor.cc @@ -1,6 +1,6 @@ // 2004-12-29 Paolo Carlini <pcarlini@suse.de> // -// Copyright (C) 2004 Free Software Foundation, Inc. +// Copyright (C) 2004, 2005, 2006, 2007 Free Software Foundation, Inc. // // This file is part of the GNU ISO C++ Library. This library is free // software; you can redistribute it and/or modify it under the @@ -48,9 +48,7 @@ void test01() int (ClassType::*[2][3])>(true)) ); VERIFY( (test_category<has_nothrow_constructor, int (ClassType::*[][2][3]) (int)>(true)) ); - - // Sanity check. - VERIFY( (test_category<has_nothrow_constructor, ClassType>(false)) ); + VERIFY( (test_category<has_nothrow_constructor, ClassType>(true)) ); } int main() diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_trivial_constructor/has_trivial_constructor.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_trivial_constructor/has_trivial_constructor.cc index 77dcf1f..f6b1a1a 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_trivial_constructor/has_trivial_constructor.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_trivial_constructor/has_trivial_constructor.cc @@ -1,6 +1,6 @@ // 2004-12-26 Paolo Carlini <pcarlini@suse.de> // -// Copyright (C) 2004 Free Software Foundation, Inc. +// Copyright (C) 2004, 2005, 2006, 2007 Free Software Foundation, Inc. // // This file is part of the GNU ISO C++ Library. This library is free // software; you can redistribute it and/or modify it under the @@ -48,9 +48,7 @@ void test01() int (ClassType::*[2][3])>(true)) ); VERIFY( (test_category<has_trivial_constructor, int (ClassType::*[][2][3]) (int)>(true)) ); - - // Sanity check. - VERIFY( (test_category<has_trivial_constructor, ClassType>(false)) ); + VERIFY( (test_category<has_trivial_constructor, ClassType>(true)) ); } int main() diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_trivial_destructor/has_trivial_destructor.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_trivial_destructor/has_trivial_destructor.cc index 3af9c26..197de98 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_trivial_destructor/has_trivial_destructor.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_trivial_destructor/has_trivial_destructor.cc @@ -1,6 +1,6 @@ // 2004-12-26 Paolo Carlini <pcarlini@suse.de> // -// Copyright (C) 2004 Free Software Foundation, Inc. +// Copyright (C) 2004, 2005, 2006, 2007 Free Software Foundation, Inc. // // This file is part of the GNU ISO C++ Library. This library is free // software; you can redistribute it and/or modify it under the @@ -48,9 +48,7 @@ void test01() int (ClassType::*[2][3])>(true)) ); VERIFY( (test_category<has_trivial_destructor, int (ClassType::*[][2][3]) (int)>(true)) ); - - // Sanity check. - VERIFY( (test_category<has_trivial_destructor, ClassType>(false)) ); + VERIFY( (test_category<has_trivial_destructor, ClassType>(true)) ); } int main() diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/is_pod/is_pod.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/is_pod/is_pod.cc index 116af85..12a4a45 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/is_pod/is_pod.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/is_pod/is_pod.cc @@ -1,6 +1,6 @@ // 2004-12-26 Paolo Carlini <pcarlini@suse.de> // -// Copyright (C) 2004 Free Software Foundation, Inc. +// Copyright (C) 2004, 2005, 2006, 2007 Free Software Foundation, Inc. // // This file is part of the GNU ISO C++ Library. This library is free // software; you can redistribute it and/or modify it under the @@ -45,9 +45,7 @@ void test01() VERIFY( (test_category<is_pod, int(*[][2])(int)>(true)) ); VERIFY( (test_category<is_pod, int (ClassType::*[2][3])>(true)) ); VERIFY( (test_category<is_pod, int (ClassType::*[][2][3]) (int)>(true)) ); - - // Sanity check. - VERIFY( (test_category<is_pod, ClassType>(false)) ); + VERIFY( (test_category<is_pod, ClassType>(true)) ); } int main() |