public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/57765] [C++11] Variadic Template Specialization does not follow the INCITS/ISO​/IEC 14882-2011 standard
       [not found] <bug-57765-4@http.gcc.gnu.org/bugzilla/>
@ 2013-07-01  9:28 ` trashyankes at wp dot pl
  2013-07-01 12:53 ` aaronngray.lists at gmail dot com
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 4+ messages in thread
From: trashyankes at wp dot pl @ 2013-07-01  9:28 UTC (permalink / raw)
  To: gcc-bugs

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

trashyankes at wp dot pl changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |trashyankes at wp dot pl

--- Comment #1 from trashyankes at wp dot pl ---
In version of C++0x standard I have (not final, 2011-02-28 N3225) section 14.1
paragraph 11:
"If a template-parameter of a class template has a default template-argument,
each subsequent template-parameter shall either have a default
template-argument supplied or be a template parameter pack. If a
template-parameter of a primary class template is a template parameter pack, it
shall be the last template-parameter. [ Note: These are not requirements for
function templates or class template partial specializations
because template arguments can be deduced (...) — end note ]"
If this is not changed then first example is valid and second isnt because you
cant deduced value of `int`.
>From gcc-bugs-return-425514-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Jul 01 09:33:02 2013
Return-Path: <gcc-bugs-return-425514-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 4665 invoked by alias); 1 Jul 2013 09:33:02 -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 4537 invoked by uid 48); 1 Jul 2013 09:32:58 -0000
From: "dominiq at lps dot ens.fr" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug fortran/54788] ICE on pointer-array element assignment
Date: Mon, 01 Jul 2013 09:33:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: fortran
X-Bugzilla-Version: 4.8.0
X-Bugzilla-Keywords: ice-on-invalid-code
X-Bugzilla-Severity: normal
X-Bugzilla-Who: dominiq at lps dot ens.fr
X-Bugzilla-Status: RESOLVED
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-54788-4-6s1H2FbtLP@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-54788-4@http.gcc.gnu.org/bugzilla/>
References: <bug-54788-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-07/txt/msg00021.txt.bz2
Content-length: 148

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

--- Comment #9 from Dominique d'Humieres <dominiq at lps dot ens.fr> ---
Thanks for the commit.


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

* [Bug c++/57765] [C++11] Variadic Template Specialization does not follow the INCITS/ISO​/IEC 14882-2011 standard
       [not found] <bug-57765-4@http.gcc.gnu.org/bugzilla/>
  2013-07-01  9:28 ` [Bug c++/57765] [C++11] Variadic Template Specialization does not follow the INCITS/ISO​/IEC 14882-2011 standard trashyankes at wp dot pl
@ 2013-07-01 12:53 ` aaronngray.lists at gmail dot com
  2013-07-01 21:52 ` trashyankes at wp dot pl
  2013-07-02 21:38 ` aaronngray.lists at gmail dot com
  3 siblings, 0 replies; 4+ messages in thread
From: aaronngray.lists at gmail dot com @ 2013-07-01 12:53 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #2 from AaronNGray <aaronngray.lists at gmail dot com> ---
Interesting ...from the standard, not in braces :-
"A template parameter pack of a function template shall not be followed by
another template parameter unless that template parameter can be deduced or has
a default argument"

The two paragraphs in full :-

14.1 [11] If a template-parameter of a class template or alias template has a
default template-argument, each subsequent template-parameter shall either have
a default template-argument supplied or be a template parameter pack. If a
template-parameter of a primary class template or alias template is a template
parameter pack, it shall be the last template-parameter. A template parameter
pack of a function template shall not be followed by another template parameter
unless that template parameter can be deduced or has a default argument
(14.8.2).

14.1 [15] If a template-parameter is a type-parameter with an ellipsis prior to
its optional identifier or is a parameter-declaration that declares a parameter
pack (8.3.5), then the template-parameter is a template parameter pack
(14.5.3). A template parameter pack that is a parameter-declaration whose type
contains one or more unexpanded parameter packs is a pack expansion. Similarly,
a template parameter pack that is a type-parameter with a
template-parameter-list containing one or more unexpanded parameter packs is a
pack expansion. 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] 4+ messages in thread

* [Bug c++/57765] [C++11] Variadic Template Specialization does not follow the INCITS/ISO​/IEC 14882-2011 standard
       [not found] <bug-57765-4@http.gcc.gnu.org/bugzilla/>
  2013-07-01  9:28 ` [Bug c++/57765] [C++11] Variadic Template Specialization does not follow the INCITS/ISO​/IEC 14882-2011 standard trashyankes at wp dot pl
  2013-07-01 12:53 ` aaronngray.lists at gmail dot com
@ 2013-07-01 21:52 ` trashyankes at wp dot pl
  2013-07-02 21:38 ` aaronngray.lists at gmail dot com
  3 siblings, 0 replies; 4+ messages in thread
From: trashyankes at wp dot pl @ 2013-07-01 21:52 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #3 from trashyankes at wp dot pl ---
I see, they fix wording in final version, but meaning didnt change (at last if
I understand it correctly).

"(...) primary class template or alias template is a template parameter pack,
it shall be the last template-parameter"


    template <typename ... Ts> //<-this is a "primary class template" 
    class Foo { };

    template <typename TR, typename ... Ts, TR (&f)(Ts...)> 
        //   ^-- this isnt a "primary class template"
    struct OpF<TR (Ts...), f> //<-this is a "primary class template"
    { };

"(...) function template shall not be followed by another template parameter
unless that template parameter can be deduced (...)"

    template < typename TR, typename ... Ts, int i> TR tester(Ts...);
                   //      cant be deduced --^


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

* [Bug c++/57765] [C++11] Variadic Template Specialization does not follow the INCITS/ISO​/IEC 14882-2011 standard
       [not found] <bug-57765-4@http.gcc.gnu.org/bugzilla/>
                   ` (2 preceding siblings ...)
  2013-07-01 21:52 ` trashyankes at wp dot pl
@ 2013-07-02 21:38 ` aaronngray.lists at gmail dot com
  3 siblings, 0 replies; 4+ messages in thread
From: aaronngray.lists at gmail dot com @ 2013-07-02 21:38 UTC (permalink / raw)
  To: gcc-bugs

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

AaronNGray <aaronngray.lists at gmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|---                         |INVALID

--- Comment #4 from AaronNGray <aaronngray.lists at gmail dot com> ---
If a template-parameter of a primary class template or alias template is a
template parameter pack, it shall be the last template-parameter.

template <typename TR, typename ... Ts, TR (&f)(Ts...)> struct
 OpF<TR (Ts...), f> { };


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

end of thread, other threads:[~2013-07-02 21:38 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <bug-57765-4@http.gcc.gnu.org/bugzilla/>
2013-07-01  9:28 ` [Bug c++/57765] [C++11] Variadic Template Specialization does not follow the INCITS/ISO​/IEC 14882-2011 standard trashyankes at wp dot pl
2013-07-01 12:53 ` aaronngray.lists at gmail dot com
2013-07-01 21:52 ` trashyankes at wp dot pl
2013-07-02 21:38 ` aaronngray.lists at gmail 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).