type_traits (__add_lvalue_reference_helper, [...]): As an optimization, rewrite condition (avoid is_function).

2009-03-14  Paolo Carlini  <paolo.carlini@oracle.com>

	* include/std/type_traits (__add_lvalue_reference_helper,
	__add_rvalue_reference_helper): As an optimization, rewrite
	condition (avoid is_function).

From-SVN: r144868
This commit is contained in:
Paolo Carlini 2009-03-15 00:56:31 +00:00 committed by Paolo Carlini
parent b16a619688
commit 58366b08d7
2 changed files with 8 additions and 2 deletions

View File

@ -1,3 +1,9 @@
2009-03-14 Paolo Carlini <paolo.carlini@oracle.com>
* include/std/type_traits (__add_lvalue_reference_helper,
__add_rvalue_reference_helper): As an optimization, rewrite
condition (avoid is_function).
2009-03-13 Paolo Carlini <paolo.carlini@oracle.com>
PR libstdc++/39405

View File

@ -111,7 +111,7 @@ namespace std
{ typedef _Tp type; };
template<typename _Tp,
bool = is_object<_Tp>::value || is_function<_Tp>::value,
bool = !is_reference<_Tp>::value && !is_void<_Tp>::value,
bool = is_rvalue_reference<_Tp>::value>
struct __add_lvalue_reference_helper
{ typedef _Tp type; };
@ -131,7 +131,7 @@ namespace std
{ };
template<typename _Tp,
bool = is_object<_Tp>::value || is_function<_Tp>::value>
bool = !is_reference<_Tp>::value && !is_void<_Tp>::value>
struct __add_rvalue_reference_helper
{ typedef _Tp type; };