public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/67397] New: GCC incorrectly accepts non-type template parameter pack expansion of a parameter pack declared in the same template-parameter-list
@ 2015-08-30  0:53 brunocodutra at gmail dot com
  2021-07-31 21:14 ` [Bug c++/67397] " pinskia at gcc dot gnu.org
  2021-07-31 21:20 ` pinskia at gcc dot gnu.org
  0 siblings, 2 replies; 3+ messages in thread
From: brunocodutra at gmail dot com @ 2015-08-30  0:53 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67397

            Bug ID: 67397
           Summary: GCC incorrectly accepts non-type template parameter
                    pack expansion of a parameter pack declared in the
                    same template-parameter-list
           Product: gcc
           Version: 5.2.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: brunocodutra at gmail dot com
  Target Milestone: ---

The following is incorrectly accepted by GCC (and clang but not MSVC 14)

template<typename...>
struct foo;

template<typename... t, t... v>
struct foo<std::integral_constant<t, v>...>
{
    using type = foo;
};

using bar = foo<std::integral_constant<int, -1>, std::true_type>::type;

[temp.param]/p15:

"A template parameter pack that is a pack expansion shall not expand a
parameter pack declared in the same template-parameter-list."


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

* [Bug c++/67397] GCC incorrectly accepts non-type template parameter pack expansion of a parameter pack declared in the same template-parameter-list
  2015-08-30  0:53 [Bug c++/67397] New: GCC incorrectly accepts non-type template parameter pack expansion of a parameter pack declared in the same template-parameter-list brunocodutra at gmail dot com
@ 2021-07-31 21:14 ` pinskia at gcc dot gnu.org
  2021-07-31 21:20 ` pinskia at gcc dot gnu.org
  1 sibling, 0 replies; 3+ messages in thread
From: pinskia at gcc dot gnu.org @ 2021-07-31 21:14 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67397

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                URL|http://stackoverflow.com/q/ |
                   |31954078/801438             |

--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
http://stackoverflow.com/q/31954078/801438

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

* [Bug c++/67397] GCC incorrectly accepts non-type template parameter pack expansion of a parameter pack declared in the same template-parameter-list
  2015-08-30  0:53 [Bug c++/67397] New: GCC incorrectly accepts non-type template parameter pack expansion of a parameter pack declared in the same template-parameter-list brunocodutra at gmail dot com
  2021-07-31 21:14 ` [Bug c++/67397] " pinskia at gcc dot gnu.org
@ 2021-07-31 21:20 ` pinskia at gcc dot gnu.org
  1 sibling, 0 replies; 3+ messages in thread
From: pinskia at gcc dot gnu.org @ 2021-07-31 21:20 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67397

--- Comment #2 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
ICC 2021.3.0 rejects it.
MSVC 19.14+, clang trunk and GCC trunk all accept it

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

end of thread, other threads:[~2021-07-31 21:20 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-08-30  0:53 [Bug c++/67397] New: GCC incorrectly accepts non-type template parameter pack expansion of a parameter pack declared in the same template-parameter-list brunocodutra at gmail dot com
2021-07-31 21:14 ` [Bug c++/67397] " pinskia at gcc dot gnu.org
2021-07-31 21:20 ` pinskia at gcc dot gnu.org

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).