This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c++/53585] template value parameter of pointer-to-member type incorrectly rejects non-direct values


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

Daniel KrÃgler <daniel.kruegler at googlemail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |daniel.kruegler at
                   |                            |googlemail dot com

--- Comment #1 from Daniel KrÃgler <daniel.kruegler at googlemail dot com> 2012-06-06 07:48:59 UTC ---
This looks like a clang extension to me, even though I must say that the
standard is currently not as clear as it could be (Keeping in mind that the
core language is currently considering to extend the valid forms of non-type
template parameters). The relevant wording from 14.3.2 p1 here is:

"A template-argument for a non-type, non-template template-parameter shall be
one of:
[..]
â a pointer to member expressed as described in 5.3.1."

I interpret this conservatively such that only an unary expression of the form
&qualified-id is valid here as described in p3+4 of 5.3.1.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]