Bug 81215 - [7/8 Regression] deduction failure with variadic template template parameter
Summary: [7/8 Regression] deduction failure with variadic template template parameter
Status: RESOLVED FIXED
Alias: None
Product: gcc
Classification: Unclassified
Component: c++ (show other bugs)
Version: 7.1.0
: P2 normal
Target Milestone: 7.2
Assignee: Jason Merrill
URL:
Keywords: rejects-valid
Depends on:
Blocks:
 
Reported: 2017-06-26 18:34 UTC by Jason Merrill
Modified: 2017-06-27 08:12 UTC (History)
1 user (show)

See Also:
Host:
Target:
Build:
Known to work:
Known to fail:
Last reconfirmed: 2017-06-26 00:00:00


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jason Merrill 2017-06-26 18:34:38 UTC
From https://bugzilla.redhat.com/show_bug.cgi?id=1464612

template<typename U> struct X { };
template<typename T, typename U = void> struct set { };

template <typename V, template <typename...> class C>
void bar (const X<C<V>>&)
{
}

void
foo (X<set<int>>& x)
{
  bar (x);
}
Comment 1 Jason Merrill 2017-06-26 18:49:49 UTC
Author: jason
Date: Mon Jun 26 18:49:18 2017
New Revision: 249664

URL: https://gcc.gnu.org/viewcvs?rev=249664&root=gcc&view=rev
Log:
	PR c++/81215 - deduction failure with variadic TTP.

	* pt.c (unify_bound_ttp_args): Restore old logic for C++14 and down.

Added:
    trunk/gcc/testsuite/g++.dg/cpp0x/variadic-ttp7.C
Modified:
    trunk/gcc/cp/ChangeLog
    trunk/gcc/cp/pt.c
Comment 2 Jason Merrill 2017-06-26 18:49:58 UTC
Author: jason
Date: Mon Jun 26 18:49:25 2017
New Revision: 249665

URL: https://gcc.gnu.org/viewcvs?rev=249665&root=gcc&view=rev
Log:
	PR c++/81215

	* pt.c (unify_bound_ttp_args): Restore old logic for C++14 and down.

Added:
    branches/gcc-7-branch/gcc/testsuite/g++.dg/cpp0x/variadic-ttp7.C
Modified:
    branches/gcc-7-branch/gcc/cp/ChangeLog
    branches/gcc-7-branch/gcc/cp/pt.c
Comment 3 Richard Biener 2017-06-27 08:12:17 UTC
Fixed.