diff options
author | Argyrios Kyrtzidis <akyrtzi@gmail.com> | 2011-07-01 22:23:09 +0000 |
---|---|---|
committer | Argyrios Kyrtzidis <akyrtzi@gmail.com> | 2011-07-01 22:23:09 +0000 |
commit | 05d4876a64865e34366b58fc8a6848c3cde895d9 (patch) | |
tree | 9fa167128cf034504d4a859c21638764ee285eaf /lib/Sema/SemaType.cpp | |
parent | a8349f5e60d1b5b0e658195a60d385b56ed440ec (diff) |
Fix the warning that is emitted when an ownership attribute is applied incorrectly.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@134278 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/SemaType.cpp')
-rw-r--r-- | lib/Sema/SemaType.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/Sema/SemaType.cpp b/lib/Sema/SemaType.cpp index cc4389ef15..cd4a5b50d8 100644 --- a/lib/Sema/SemaType.cpp +++ b/lib/Sema/SemaType.cpp @@ -87,6 +87,11 @@ static void diagnoseBadTypeAttribute(Sema &S, const AttributeList &attr, useInstantiationLoc = true; break; + case AttributeList::AT_objc_ownership: + diagID = diag::warn_objc_object_attribute_wrong_type; + useInstantiationLoc = true; + break; + default: // Assume everything else was a function attribute. diagID = diag::warn_function_attribute_wrong_type; |