Disambiguate __gnu_cxx::append_ partial specialization

This patch corrects ambiguous partial specializations of
typelist::detail::append_.  Previously, neither append_<chain<Hd, Tl>,
Typelist_Chain> nor append_<Typelist_Chain, null_type> was a better
match for append_<chain<Hd, Tl>, null_type>.

2019-02-22  Tom Honermann  <tom@honermann.net>

	* include/ext/typelist.h: Constrain a partial specialization of
	typelist::detail::append_ to only match chain<T1,T2>.

From-SVN: r269088
This commit is contained in:
Tom Honermann 2019-02-22 01:15:58 +00:00 committed by Jonathan Wakely
parent f08e60e988
commit 65bbaf3125
2 changed files with 8 additions and 3 deletions

View File

@ -1,3 +1,8 @@
2019-02-22 Tom Honermann <tom@honermann.net>
* include/ext/typelist.h: Constrain a partial specialization of
typelist::detail::append_ to only match chain<T1,T2>.
2019-02-21 Jonathan Wakely <jwakely@redhat.com>
PR libstdc++/89416

View File

@ -215,10 +215,10 @@ namespace detail
typedef Typelist_Chain type;
};
template<typename Typelist_Chain>
struct append_<Typelist_Chain, null_type>
template<typename Hd, typename Tl>
struct append_<chain<Hd, Tl>, null_type>
{
typedef Typelist_Chain type;
typedef chain<Hd, Tl> type;
};
template<>