diff options
Diffstat (limited to 'Sema/SemaExpr.cpp')
-rw-r--r-- | Sema/SemaExpr.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/Sema/SemaExpr.cpp b/Sema/SemaExpr.cpp index 9208db26a8..b613cd90a2 100644 --- a/Sema/SemaExpr.cpp +++ b/Sema/SemaExpr.cpp @@ -1157,6 +1157,9 @@ inline QualType Sema::CheckCompareOperands( // C99 6.5.8 if (lType->isRealType() && rType->isRealType()) return Context.IntTy; } else { + if (lType->isRealType() && rType->isRealType()) + Diag(loc, diag::warn_floatingpoint_eq); + if (lType->isArithmeticType() && rType->isArithmeticType()) return Context.IntTy; } |