[PATCH] Adding a diagnostic for member templates inside a local class
YunZhong Gao
gaoyunzhong at gmail.com
Fri Sep 20 18:55:49 PDT 2013
GCC 4.6.3 gives the following diagnostic and rejects the program (the example as in
http://llvm-reviews.chandlerc.com/D575#summary)
$ g++ -std=c++0x -S -o - test.cc
test.cc: In function ‘int test()’:
test.cc:4:5: error: invalid declaration of member template in local class
On the other hand, I noticed some recent work that seems to be adding support for member
templates inside local classes. Is C++14 going to support this as an extension?
For example,
If this change goes in, many tests in
test/SemaTemplate/local-member-templates.cpp
will be invalidated.
I will also need to revert r184903, which implements PCH support for member templates in local classes.
RIchard and Faisal, what is your opinion/advice on this?
http://llvm-reviews.chandlerc.com/D575
More information about the cfe-commits
mailing list