summaryrefslogtreecommitdiffstats
path: root/clang/lib/Sema/SemaExpr.cpp
diff options
context:
space:
mode:
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