summaryrefslogtreecommitdiffstats
path: root/clang/test/SemaCXX/warn-thread-safety-parsing.cpp
diff options
context:
space:
mode:
authorDeLesley Hutchins <delesley@google.com>2012-03-02 22:12:59 +0000
committerDeLesley Hutchins <delesley@google.com>2012-03-02 22:12:59 +0000
commitbd2ee13e78bae1f461628a038c584ba42a35697c (patch)
tree00da1a588aa491de1cb7879c6c4eb7e200769f85 /clang/test/SemaCXX/warn-thread-safety-parsing.cpp
parenta2587ef26d802ccc00b7853ffdab7b8070a67ad8 (diff)
downloadbcm5719-llvm-bd2ee13e78bae1f461628a038c584ba42a35697c.tar.gz
bcm5719-llvm-bd2ee13e78bae1f461628a038c584ba42a35697c.zip
Make late-parsed attributes follow the conventions of ordinary
GNU attributes to a better extent, by allowing them in more places on a declator. llvm-svn: 151945
Diffstat (limited to 'clang/test/SemaCXX/warn-thread-safety-parsing.cpp')
-rw-r--r--clang/test/SemaCXX/warn-thread-safety-parsing.cpp16
1 files changed, 16 insertions, 0 deletions
diff --git a/clang/test/SemaCXX/warn-thread-safety-parsing.cpp b/clang/test/SemaCXX/warn-thread-safety-parsing.cpp
index c58ff9314ec..2e5106ce8a3 100644
--- a/clang/test/SemaCXX/warn-thread-safety-parsing.cpp
+++ b/clang/test/SemaCXX/warn-thread-safety-parsing.cpp
@@ -1287,5 +1287,21 @@ template <class T>
void Bar<T>::bar() __attribute__((exclusive_locks_required(mu_))) { }
void baz(Foo *f) __attribute__((exclusive_locks_required(f->mu_))) { }
+
+} // end namespace
+
+
+namespace TestMultiDecl {
+
+class Foo {
+public:
+ int __attribute__((guarded_by(mu_))) a;
+ int __attribute__((guarded_by(mu_))) b, c;
+
+private:
+ Mu mu_;
};
+
+} // end namespace TestMultiDecl
+
OpenPOWER on IntegriCloud