From: Chris Lattner Date: Tue, 25 Sep 2007 04:29:44 +0000 (+0000) Subject: use the right rounding mode. X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=92dfb4784fa4451569e985894a5accd257b98b6b;p=clang use the right rounding mode. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@42291 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/AST/Expr.cpp b/AST/Expr.cpp index 98963de633..ce6636a52a 100644 --- a/AST/Expr.cpp +++ b/AST/Expr.cpp @@ -753,7 +753,7 @@ bool Expr::isIntegerConstantExpr(llvm::APSInt &Result, ASTContext &Ctx, llvm::APFloat::opStatus Status = FL->getValue().convertToInteger(Space, DestWidth, DestSigned, - llvm::APFloat::rmNearestTiesToEven); + llvm::APFloat::rmTowardZero); if (Status != llvm::APFloat::opOK && Status != llvm::APFloat::opInexact) { if (Loc) *Loc = Operand->getLocStart(); return false; // FIXME: need to accept this as an extension.