From c2eb303f884db168a3da5407b7dc31a9996f9faa Mon Sep 17 00:00:00 2001 From: Eric Botcazou Date: Tue, 6 Mar 2018 12:21:50 +0000 Subject: [PATCH] trans.c (convert_with_check): Fix typo in the condition guarding the overflow check emitted for the upper... * gcc-interface/trans.c (convert_with_check): Fix typo in the condition guarding the overflow check emitted for the upper bound of a floating- point conversion. From-SVN: r258279 --- gcc/ada/ChangeLog | 6 ++++++ gcc/ada/gcc-interface/trans.c | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/gcc/ada/ChangeLog b/gcc/ada/ChangeLog index aca3c23380fe..67abd8fcf94c 100644 --- a/gcc/ada/ChangeLog +++ b/gcc/ada/ChangeLog @@ -1,3 +1,9 @@ +2018-03-06 Eric Botcazou + + * gcc-interface/trans.c (convert_with_check): Fix typo in the condition + guarding the overflow check emitted for the upper bound of a floating- + point conversion. + 2017-12-14 Eric Botcazou * gcc-interface/decl.c (gnat_to_gnu_field): Do not set the alignment diff --git a/gcc/ada/gcc-interface/trans.c b/gcc/ada/gcc-interface/trans.c index 8a4924c9f28d..245994181f34 100644 --- a/gcc/ada/gcc-interface/trans.c +++ b/gcc/ada/gcc-interface/trans.c @@ -9215,7 +9215,7 @@ convert_with_check (Entity_Id gnat_type, tree gnu_expr, bool overflowp, ? tree_int_cst_lt (gnu_out_ub, gnu_in_ub) : (FLOAT_TYPE_P (gnu_base_type) ? real_less (&TREE_REAL_CST (gnu_out_ub), - &TREE_REAL_CST (gnu_in_lb)) + &TREE_REAL_CST (gnu_in_ub)) : 1)) gnu_cond = build_binary_op (TRUTH_ORIF_EXPR, boolean_type_node, gnu_cond, -- 2.47.2