aboutsummaryrefslogtreecommitdiff
path: root/lib/Sema/SemaDeclAttr.cpp
diff options
context:
space:
mode:
authorArgyrios Kyrtzidis <akyrtzi@gmail.com>2010-12-06 17:51:53 +0000
committerArgyrios Kyrtzidis <akyrtzi@gmail.com>2010-12-06 17:51:53 +0000
commit223ae5c26654e5fd7dacdafe43aff28a096ba63b (patch)
tree73fc44550f6146c02c651c57f0763ea2be29e92a /lib/Sema/SemaDeclAttr.cpp
parentf0b0ccce127857e7e4fb829e017dbcb7487884c4 (diff)
Use Sema's MarkDeclarationReferenced, which takes care of templates, instead of calling Decl's setUsed directly.
Thanks to John for the hint! git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@121014 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/SemaDeclAttr.cpp')
-rw-r--r--lib/Sema/SemaDeclAttr.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Sema/SemaDeclAttr.cpp b/lib/Sema/SemaDeclAttr.cpp
index d53fd6822d..05b141b245 100644
--- a/lib/Sema/SemaDeclAttr.cpp
+++ b/lib/Sema/SemaDeclAttr.cpp
@@ -1452,7 +1452,7 @@ static void HandleCleanupAttr(Decl *d, const AttributeList &Attr, Sema &S) {
}
d->addAttr(::new (S.Context) CleanupAttr(Attr.getLoc(), S.Context, FD));
- FD->setUsed();
+ S.MarkDeclarationReferenced(Attr.getParameterLoc(), FD);
}
/// Handle __attribute__((format_arg((idx)))) attribute based on