]> granicus.if.org Git - clang/commitdiff
Check for deprecated implementation unconditionally.
authorFariborz Jahanian <fjahanian@apple.com>
Wed, 16 Feb 2011 00:30:31 +0000 (00:30 +0000)
committerFariborz Jahanian <fjahanian@apple.com>
Wed, 16 Feb 2011 00:30:31 +0000 (00:30 +0000)
Warning and its note will be ignored in default case.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@125621 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Sema/SemaDeclObjC.cpp

index 075393b4ed48c575e2c305529da02d1004d81ac3..102289b032eba75b51ce7207e19c9c77114eba84 100644 (file)
@@ -28,12 +28,8 @@ static void DiagnoseObjCImplementedDeprecations(Sema &S,
                                                 NamedDecl *ND,
                                                 SourceLocation ImplLoc,
                                                 int select) {
-  
-  unsigned DIAG = diag::warn_deprecated_def;
-  if (S.Diags.getDiagnosticLevel(DIAG, ImplLoc)== Diagnostic::Ignored)
-    return;
   if (ND && ND->getAttr<DeprecatedAttr>()) {
-    S.Diag(ImplLoc, DIAG) << select;
+    S.Diag(ImplLoc, diag::warn_deprecated_def) << select;
     if (select == 0)
       S.Diag(ND->getLocation(), diag::note_method_declared_at);
     else