summaryrefslogtreecommitdiffstats
path: root/clang/lib/Sema/SemaTemplate.cpp
diff options
context:
space:
mode:
authorDouglas Gregor <dgregor@apple.com>2011-11-07 20:56:01 +0000
committerDouglas Gregor <dgregor@apple.com>2011-11-07 20:56:01 +0000
commit5d1b4e3d1f63a7761337cfc4535eb10d5ee3ec4a (patch)
tree6f75dadf4870230820e1f48deb2d30fc04ccb9d9 /clang/lib/Sema/SemaTemplate.cpp
parent7f076cb6cc537a1ef77bf2a16549394f03605d33 (diff)
downloadbcm5719-llvm-5d1b4e3d1f63a7761337cfc4535eb10d5ee3ec4a.tar.gz
bcm5719-llvm-5d1b4e3d1f63a7761337cfc4535eb10d5ee3ec4a.zip
When we notice that a member function is defined with "= delete" or "=
default", make a note of which is used when creating the initial declaration. Previously, we would wait until later to handle default/delete as a definition, but this is too late: when adding the declaration, we already treated the declaration as "user-provided" when in fact it was merely "user-declared". Fixes PR10861 and PR10442, along with a bunch of FIXMEs. llvm-svn: 144011
Diffstat (limited to 'clang/lib/Sema/SemaTemplate.cpp')
-rw-r--r--clang/lib/Sema/SemaTemplate.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/lib/Sema/SemaTemplate.cpp b/clang/lib/Sema/SemaTemplate.cpp
index 2d7e85094aa..8ec4c195f91 100644
--- a/clang/lib/Sema/SemaTemplate.cpp
+++ b/clang/lib/Sema/SemaTemplate.cpp
@@ -5219,7 +5219,7 @@ Decl *Sema::ActOnStartOfFunctionTemplateDef(Scope *FnBodyScope,
Scope *ParentScope = FnBodyScope->getParent();
- D.setFunctionDefinition(true);
+ D.setFunctionDefinitionKind(FDK_Definition);
Decl *DP = HandleDeclarator(ParentScope, D,
move(TemplateParameterLists));
if (FunctionTemplateDecl *FunctionTemplate
OpenPOWER on IntegriCloud