--- p/predef.c.orig Thu Jul 3 02:28:52 2003 +++ p/predef.c Fri Jul 4 19:13:22 2003 @@ -1679,11 +1679,13 @@ if (r_num == p_Round) { /* ISO Pascal: Round (x) := Trunc (x >= 0.0 ? x + 0.5 : x - 0.5); */ + tree t = TYPE_PRECISION (type) > TYPE_PRECISION (double_type_node) + ? long_double_type_node : double_type_node; val = save_expr (val); - val = build (COND_EXPR, type, + val = build (COND_EXPR, t, build_pascal_binary_op (GE_EXPR, val, real_zero_node), - build_pascal_binary_op (PLUS_EXPR, val, real_half_node), - build_pascal_binary_op (MINUS_EXPR, val, real_half_node)); + convert (t, build_pascal_binary_op (PLUS_EXPR, val, real_half_node)), + convert (t, build_pascal_binary_op (MINUS_EXPR, val, real_half_node))); } /* @@ Check the return value; maybe wrong TRUNC_EXPR used. */ retval = convert (long_long_integer_type_node, val);