summaryrefslogtreecommitdiffstats
path: root/clang/lib/Sema/SemaExpr.cpp
diff options
context:
space:
mode:
authorManman Ren <manman.ren@gmail.com>2016-02-22 04:47:24 +0000
committerManman Ren <manman.ren@gmail.com>2016-02-22 04:47:24 +0000
commitd8039df5231cb23fe332e70ecb6f064179ec0352 (patch)
treed0399039d694dde88d0c9c3c61480797f145091f /clang/lib/Sema/SemaExpr.cpp
parente59c8af7059f2ba1d65ea421a8ba4a739ed80372 (diff)
downloadbcm5719-llvm-d8039df5231cb23fe332e70ecb6f064179ec0352.tar.gz
bcm5719-llvm-d8039df5231cb23fe332e70ecb6f064179ec0352.zip
Addressing review comments for r261163.
Use "strict" instead of "nopartial". Also make strictly not-introduced share the same diagnostics as Obsolete and Unavailable. rdar://23791325 llvm-svn: 261512
Diffstat (limited to 'clang/lib/Sema/SemaExpr.cpp')
-rw-r--r--clang/lib/Sema/SemaExpr.cpp7
1 files changed, 3 insertions, 4 deletions
diff --git a/clang/lib/Sema/SemaExpr.cpp b/clang/lib/Sema/SemaExpr.cpp
index ad6280d6c74..bfbca298ce8 100644
--- a/clang/lib/Sema/SemaExpr.cpp
+++ b/clang/lib/Sema/SemaExpr.cpp
@@ -159,12 +159,11 @@ DiagnoseAvailabilityOfDecl(Sema &S, NamedDecl *D, SourceLocation Loc,
break;
case AR_NotYetIntroduced: {
- // With nopartial, the compiler will emit delayed error just like how
- // "deprecated, unavailable" are handled.
+ // With strict, the compiler will emit unavailable error.
AvailabilityAttr *AA = D->getAttr<AvailabilityAttr>();
- if (AA && AA->getNopartial() &&
+ if (AA && AA->getStrict() &&
S.getCurContextAvailability() != AR_NotYetIntroduced)
- S.EmitAvailabilityWarning(Sema::AD_NotYetIntroduced,
+ S.EmitAvailabilityWarning(Sema::AD_Unavailable,
D, Message, Loc, UnknownObjCClass, ObjCPDecl,
ObjCPropertyAccess);
OpenPOWER on IntegriCloud