[prev in list] [next in list] [prev in thread] [next in thread]
List: gcc
Subject: Unused case statements in expand_expr
From: Nick Burrett <nick.burrett () btinternet ! com>
Date: 1998-06-23 15:44:55
[Download RAW message or body]
In `expand_expr' we have:
case FIX_ROUND_EXPR:
case FIX_FLOOR_EXPR:
case FIX_CEIL_EXPR:
abort (); /* Not used for C. */
Since expr.c is `supposed' to be language-independent then can I remove
these case statements ? The end result is that `abort' will be called anyway.
It also means that languages that wish to implement any of those codes
can provide them in a language specific hook through the default case
`lang_expand_expr'.
Nick.
<date> Nick Burrett <nick.burrett@btinternet.com>
* expr.c (expand_expr, case FIX_ROUND_EXPR): Remove.
(expand_expr, case FIX_FLOOR_EXPR, FIX_CEIL_EXPR): Remove.
*** expr.c.orig Tue Jun 23 16:31:39 1998
--- expr.c Tue Jun 23 16:35:15 1998
*************** expand_expr (exp, target, tmode, modifie
*** 6632,6648 ****
if (! safe_from_p (subtarget, TREE_OPERAND (exp, 1), 1))
subtarget = 0;
op0 = expand_expr (TREE_OPERAND (exp, 0), subtarget, VOIDmode, 0);
op1 = expand_expr (TREE_OPERAND (exp, 1), NULL_RTX, VOIDmode, 0);
return expand_divmod (1, code, mode, op0, op1, target, unsignedp);
- case FIX_ROUND_EXPR:
- case FIX_FLOOR_EXPR:
- case FIX_CEIL_EXPR:
- abort (); /* Not used for C. */
-
case FIX_TRUNC_EXPR:
op0 = expand_expr (TREE_OPERAND (exp, 0), NULL_RTX, VOIDmode, 0);
if (target == 0)
target = gen_reg_rtx (mode);
expand_fix (target, op0, unsignedp);
return target;
--- 6632,6643 ----
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic