diff options
author | Douglas Gregor <dgregor@apple.com> | 2009-03-23 23:06:20 +0000 |
---|---|---|
committer | Douglas Gregor <dgregor@apple.com> | 2009-03-23 23:06:20 +0000 |
commit | 2dc0e64e57b2a1786fa53a7dbd1d5c8e255eadb0 (patch) | |
tree | 023d0ce37041ae08a0a6e34b55a894acdeb074fe /test/SemaCXX/nested-name-spec.cpp | |
parent | 45a3c05640b1b08e7f7f69f633f899fd0e792f3c (diff) |
Template instantiation for the declarations of member functions within
a class template. At present, we can only instantiation normal
methods, but not constructors, destructors, or conversion operators.
As ever, this contains a bit of refactoring in Sema's type-checking. In
particular:
- Split ActOnFunctionDeclarator into ActOnFunctionDeclarator
(handling the declarator itself) and CheckFunctionDeclaration
(checking for the the function declaration), the latter of which
is also used by template instantiation.
- We were performing the adjustment of function parameter types in
three places; collect those into a single new routine.
- When the type of a parameter is adjusted, allocate an
OriginalParmVarDecl to keep track of the type as it was written.
- Eliminate a redundant check for out-of-line declarations of member
functions; hide more C++-specific checks on function declarations
behind if(getLangOptions().CPlusPlus).
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@67575 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/SemaCXX/nested-name-spec.cpp')
-rw-r--r-- | test/SemaCXX/nested-name-spec.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/test/SemaCXX/nested-name-spec.cpp b/test/SemaCXX/nested-name-spec.cpp index eaca56c725..4b4d435f20 100644 --- a/test/SemaCXX/nested-name-spec.cpp +++ b/test/SemaCXX/nested-name-spec.cpp @@ -101,8 +101,7 @@ void f6(int A2::RC::x); // expected-error{{parameter declarator cannot be qualif int A2::RC::x; // expected-error{{non-static data member defined out-of-line}} -void A2::CC::NC::m(); // expected-error{{out-of-line declaration of a member must be a definition}} \ - // expected-error{{out-of-line declaration of a member must be a definition}} +void A2::CC::NC::m(); // expected-error{{out-of-line declaration of a member must be a definition}} namespace E { |