summaryrefslogtreecommitdiffstats
path: root/libstdc++-v3/include/tr2
diff options
context:
space:
mode:
authorbkoz <bkoz@138bc75d-0d04-0410-961f-82ee72b054a4>2012-03-02 05:54:24 +0000
committerbkoz <bkoz@138bc75d-0d04-0410-961f-82ee72b054a4>2012-03-02 05:54:24 +0000
commit627a008abff2fa946d47e37bebf56af1f19b656b (patch)
tree2d63d06a9d6a86101f18342cd25c2d7578c4c55f /libstdc++-v3/include/tr2
parentc4053f60e08b7fc9765e277cb972d3192ea61449 (diff)
downloadppe42-gcc-627a008abff2fa946d47e37bebf56af1f19b656b.tar.gz
ppe42-gcc-627a008abff2fa946d47e37bebf56af1f19b656b.zip
2012-03-01 Michael Spertus <mike_spertus@symantec.com>
* include/tr2/type_traits (typelist): To __reflection_typelist. (first, rest, empty): Remove. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@184773 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libstdc++-v3/include/tr2')
-rw-r--r--libstdc++-v3/include/tr2/type_traits32
1 files changed, 10 insertions, 22 deletions
diff --git a/libstdc++-v3/include/tr2/type_traits b/libstdc++-v3/include/tr2/type_traits
index 9c301b30a01..eb8c012d589 100644
--- a/libstdc++-v3/include/tr2/type_traits
+++ b/libstdc++-v3/include/tr2/type_traits
@@ -1,6 +1,6 @@
// TR2 <type_traits> -*- C++ -*-
-// Copyright (C) 2011 Free Software Foundation, Inc.
+// Copyright (C) 2011, 2012 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
@@ -53,60 +53,48 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
* Simple typelist. Compile-time list of types.
*/
template<typename... _Elements>
- struct typelist;
+ struct __reflection_typelist;
/// Specialization for an empty typelist.
template<>
- struct typelist<>
+ struct __reflection_typelist<>
{
- typedef std::true_type empty;
+ typedef std::true_type empty;
};
/// Partial specialization.
template<typename _First, typename... _Rest>
- struct typelist<_First, _Rest...>
+ struct __reflection_typelist<_First, _Rest...>
{
- typedef std::false_type empty;
+ typedef std::false_type empty;
struct first
{
- typedef _First type;
+ typedef _First type;
};
struct rest
{
- typedef typelist<_Rest...> type;
+ typedef __reflection_typelist<_Rest...> type;
};
};
/// Sequence abstraction metafunctions for manipulating a typelist.
- /// Return the first type in a typelist.
- template<typename _Tp>
- struct first : public _Tp::first { };
-
- /// Return the typelist minus the first type.
- template<typename _Tp>
- struct rest : public _Tp::rest { };
-
- /// Query to see if a typelist is empty.
- template<typename _Tp>
- struct empty : public _Tp::empty { };
-
/// Enumerate all the base classes of a class. Form of a typelist.
template<typename _Tp>
struct bases
{
- typedef typelist<__bases(_Tp)...> type;
+ typedef __reflection_typelist<__bases(_Tp)...> type;
};
/// Enumerate all the direct base classes of a class. Form of a typelist.
template<typename _Tp>
struct direct_bases
{
- typedef typelist<__direct_bases(_Tp)...> type;
+ typedef __reflection_typelist<__direct_bases(_Tp)...> type;
};
/// @} group metaprogramming
OpenPOWER on IntegriCloud