public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/58856] New: [4.9 Regression] spurious 'wrong number of template arguments' error for template alias
@ 2013-10-23 20:23 st at quanttec dot com
  2013-10-24  9:05 ` [Bug c++/58856] " rguenth at gcc dot gnu.org
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: st at quanttec dot com @ 2013-10-23 20:23 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58856

            Bug ID: 58856
           Summary: [4.9 Regression] spurious 'wrong number of template
                    arguments' error for template alias
           Product: gcc
           Version: 4.9.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: st at quanttec dot com

The current trunk version of GCC fails to compile the following valid sample

template <typename T>
struct U1 {};

template <typename T1, typename... Ts>
using U2 = U1<T1>;

template <typename T1, typename... Ts>
using U3 = U2<T1, Ts...>;

> g++ -std=c++11 -Wall -Wextra test.cpp
test.cpp:8:24: error: wrong number of template arguments (2, should be 1)
 using U3 = U2<T1, Ts...>;
                        ^
test.cpp:2:8: error: provided for ‘template<class T> struct U1’
 struct U1 {};
        ^

This bug doesn't seem to exist in
g++ (GCC) 4.8.1 20130603 (Red Hat 4.8.1-1)
and in
g++ (Built by MinGW-builds project) 4.9.0 20130717 (experimental)
>From gcc-bugs-return-432584-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Wed Oct 23 20:36:34 2013
Return-Path: <gcc-bugs-return-432584-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 25153 invoked by alias); 23 Oct 2013 20:36:34 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 25126 invoked by uid 48); 23 Oct 2013 20:36:30 -0000
From: "paolo.carlini at oracle dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/58856] [4.9 Regression] spurious 'wrong number of template arguments' error for template alias
Date: Wed, 23 Oct 2013 20:36:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: c++
X-Bugzilla-Version: 4.9.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: paolo.carlini at oracle dot com
X-Bugzilla-Status: NEW
X-Bugzilla-Priority: P2
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: priority bug_status cf_reconfirmed_on everconfirmed
Message-ID: <bug-58856-4-3CBogcSrRb@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-58856-4@http.gcc.gnu.org/bugzilla/>
References: <bug-58856-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: 7bit
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2013-10/txt/msg01728.txt.bz2
Content-length: 458

http://gcc.gnu.org/bugzilla/show_bug.cgi?idX856

Paolo Carlini <paolo.carlini at oracle dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Priority|P3                          |P2
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2013-10-23
     Ever confirmed|0                           |1


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug c++/58856] [4.9 Regression] spurious 'wrong number of template arguments' error for template alias
  2013-10-23 20:23 [Bug c++/58856] New: [4.9 Regression] spurious 'wrong number of template arguments' error for template alias st at quanttec dot com
@ 2013-10-24  9:05 ` rguenth at gcc dot gnu.org
  2013-10-31 13:54 ` paolo.carlini at oracle dot com
                   ` (3 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: rguenth at gcc dot gnu.org @ 2013-10-24  9:05 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58856

Richard Biener <rguenth at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|---                         |4.9.0


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug c++/58856] [4.9 Regression] spurious 'wrong number of template arguments' error for template alias
  2013-10-23 20:23 [Bug c++/58856] New: [4.9 Regression] spurious 'wrong number of template arguments' error for template alias st at quanttec dot com
  2013-10-24  9:05 ` [Bug c++/58856] " rguenth at gcc dot gnu.org
@ 2013-10-31 13:54 ` paolo.carlini at oracle dot com
  2014-01-03  4:05 ` jason at gcc dot gnu.org
                   ` (2 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: paolo.carlini at oracle dot com @ 2013-10-31 13:54 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58856

Paolo Carlini <paolo.carlini at oracle dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |jason at gcc dot gnu.org

--- Comment #1 from Paolo Carlini <paolo.carlini at oracle dot com> ---
Caused by r201470:

    DR 1286
    * pt.c (get_underlying_template): New.
    (convert_template_argument, lookup_template_class_1): Use it.


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug c++/58856] [4.9 Regression] spurious 'wrong number of template arguments' error for template alias
  2013-10-23 20:23 [Bug c++/58856] New: [4.9 Regression] spurious 'wrong number of template arguments' error for template alias st at quanttec dot com
  2013-10-24  9:05 ` [Bug c++/58856] " rguenth at gcc dot gnu.org
  2013-10-31 13:54 ` paolo.carlini at oracle dot com
@ 2014-01-03  4:05 ` jason at gcc dot gnu.org
  2014-01-07 21:28 ` jason at gcc dot gnu.org
  2014-01-17 10:18 ` paolo.carlini at oracle dot com
  4 siblings, 0 replies; 6+ messages in thread
From: jason at gcc dot gnu.org @ 2014-01-03  4:05 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58856

Jason Merrill <jason at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |ASSIGNED
           Assignee|unassigned at gcc dot gnu.org      |jason at gcc dot gnu.org


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug c++/58856] [4.9 Regression] spurious 'wrong number of template arguments' error for template alias
  2013-10-23 20:23 [Bug c++/58856] New: [4.9 Regression] spurious 'wrong number of template arguments' error for template alias st at quanttec dot com
                   ` (2 preceding siblings ...)
  2014-01-03  4:05 ` jason at gcc dot gnu.org
@ 2014-01-07 21:28 ` jason at gcc dot gnu.org
  2014-01-17 10:18 ` paolo.carlini at oracle dot com
  4 siblings, 0 replies; 6+ messages in thread
From: jason at gcc dot gnu.org @ 2014-01-07 21:28 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58856

--- Comment #2 from Jason Merrill <jason at gcc dot gnu.org> ---
Author: jason
Date: Tue Jan  7 21:28:33 2014
New Revision: 206406

URL: http://gcc.gnu.org/viewcvs?rev=206406&root=gcc&view=rev
Log:
    PR c++/58856
    * pt.c (num_innermost_template_parms): New.
    (get_underlying_template): Use it.

Added:
    trunk/gcc/testsuite/g++.dg/cpp0x/alias-decl-39.C
Modified:
    trunk/gcc/cp/ChangeLog
    trunk/gcc/cp/pt.c


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug c++/58856] [4.9 Regression] spurious 'wrong number of template arguments' error for template alias
  2013-10-23 20:23 [Bug c++/58856] New: [4.9 Regression] spurious 'wrong number of template arguments' error for template alias st at quanttec dot com
                   ` (3 preceding siblings ...)
  2014-01-07 21:28 ` jason at gcc dot gnu.org
@ 2014-01-17 10:18 ` paolo.carlini at oracle dot com
  4 siblings, 0 replies; 6+ messages in thread
From: paolo.carlini at oracle dot com @ 2014-01-17 10:18 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58856

Paolo Carlini <paolo.carlini at oracle dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                    |RESOLVED
                 CC|jason at gcc dot gnu.org           |
         Resolution|---                         |FIXED

--- Comment #3 from Paolo Carlini <paolo.carlini at oracle dot com> ---
Thus fixed.


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2014-01-17 10:18 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-10-23 20:23 [Bug c++/58856] New: [4.9 Regression] spurious 'wrong number of template arguments' error for template alias st at quanttec dot com
2013-10-24  9:05 ` [Bug c++/58856] " rguenth at gcc dot gnu.org
2013-10-31 13:54 ` paolo.carlini at oracle dot com
2014-01-03  4:05 ` jason at gcc dot gnu.org
2014-01-07 21:28 ` jason at gcc dot gnu.org
2014-01-17 10:18 ` paolo.carlini at oracle dot com

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).