diff options
author | Richard Smith <richard-llvm@metafoo.co.uk> | 2014-07-19 01:39:17 +0000 |
---|---|---|
committer | Richard Smith <richard-llvm@metafoo.co.uk> | 2014-07-19 01:39:17 +0000 |
commit | 1b98ccc4e9576e86fb3e235bac3076472a84f875 (patch) | |
tree | 2a47686d41ac218fd7c65dea3321790f383a15e1 /clang/lib/Sema/SemaExpr.cpp | |
parent | c4e00289a78116aefc8db41979d747ab27c4bd44 (diff) | |
download | bcm5719-llvm-1b98ccc4e9576e86fb3e235bac3076472a84f875.tar.gz bcm5719-llvm-1b98ccc4e9576e86fb3e235bac3076472a84f875.zip |
PR20356: Fix all Sema warnings with mismatched ext_/warn_ versus
ExtWarn/Warnings. Mostly the name of the warning was changed to match the
semantics, but in the PR20356 cases, the warning was about valid code, so the
diagnostic was changed from ExtWarn to Warning instead.
llvm-svn: 213443
Diffstat (limited to 'clang/lib/Sema/SemaExpr.cpp')
-rw-r--r-- | clang/lib/Sema/SemaExpr.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/clang/lib/Sema/SemaExpr.cpp b/clang/lib/Sema/SemaExpr.cpp index 1db903675e5..35dad82523c 100644 --- a/clang/lib/Sema/SemaExpr.cpp +++ b/clang/lib/Sema/SemaExpr.cpp @@ -226,8 +226,8 @@ static void diagnoseUseOfInternalDeclInInlineFunction(Sema &S, if (!DowngradeWarning && UsedFn) DowngradeWarning = UsedFn->isInlined() || UsedFn->hasAttr<ConstAttr>(); - S.Diag(Loc, DowngradeWarning ? diag::ext_internal_in_extern_inline - : diag::warn_internal_in_extern_inline) + S.Diag(Loc, DowngradeWarning ? diag::ext_internal_in_extern_inline_quiet + : diag::ext_internal_in_extern_inline) << /*IsVar=*/!UsedFn << D; S.MaybeSuggestAddingStaticToDecl(Current); @@ -5547,7 +5547,7 @@ static QualType checkConditionalPointerCompatibility(Sema &S, ExprResult &LHS, QualType CompositeTy = S.Context.mergeTypes(lhptee, rhptee); if (CompositeTy.isNull()) { - S.Diag(Loc, diag::warn_typecheck_cond_incompatible_pointers) + S.Diag(Loc, diag::ext_typecheck_cond_incompatible_pointers) << LHSTy << RHSTy << LHS.get()->getSourceRange() << RHS.get()->getSourceRange(); // In this situation, we assume void* type. No especially good @@ -5677,7 +5677,7 @@ static bool checkPointerIntegerMismatch(Sema &S, ExprResult &Int, Expr *Expr1 = IsIntFirstExpr ? Int.get() : PointerExpr; Expr *Expr2 = IsIntFirstExpr ? PointerExpr : Int.get(); - S.Diag(Loc, diag::warn_typecheck_cond_pointer_integer_mismatch) + S.Diag(Loc, diag::ext_typecheck_cond_pointer_integer_mismatch) << Expr1->getType() << Expr2->getType() << Expr1->getSourceRange() << Expr2->getSourceRange(); Int = S.ImpCastExprToType(Int.get(), PointerExpr->getType(), @@ -10276,8 +10276,8 @@ ExprResult Sema::BuildBuiltinOffsetOf(SourceLocation BuiltinLoc, if (CXXRecordDecl *CRD = dyn_cast<CXXRecordDecl>(RD)) { bool IsSafe = LangOpts.CPlusPlus11? CRD->isStandardLayout() : CRD->isPOD(); unsigned DiagID = - LangOpts.CPlusPlus11? diag::warn_offsetof_non_standardlayout_type - : diag::warn_offsetof_non_pod_type; + LangOpts.CPlusPlus11? diag::ext_offsetof_non_standardlayout_type + : diag::ext_offsetof_non_pod_type; if (!IsSafe && !DidWarnAboutNonPOD && DiagRuntimeBehavior(BuiltinLoc, nullptr, |