From d85dbdb31aa8c5fbbef322cdd9f900e2b57f3356 Mon Sep 17 00:00:00 2001 From: chrbr Date: Thu, 19 Apr 2012 09:06:53 +0000 Subject: Fix #52283 error: case label does not reduce to an integer constant git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@186586 138bc75d-0d04-0410-961f-82ee72b054a4 --- gcc/convert.c | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) (limited to 'gcc/convert.c') diff --git a/gcc/convert.c b/gcc/convert.c index 8ff2e9a825a..5e6b09e0654 100644 --- a/gcc/convert.c +++ b/gcc/convert.c @@ -537,7 +537,6 @@ convert_to_integer (tree type, tree expr) else if (outprec >= inprec) { enum tree_code code; - tree tem; /* If the precision of the EXPR's type is K bits and the destination mode has more bits, and the sign is changing, @@ -555,13 +554,7 @@ convert_to_integer (tree type, tree expr) else code = NOP_EXPR; - tem = fold_unary (code, type, expr); - if (tem) - return tem; - - tem = build1 (code, type, expr); - TREE_NO_WARNING (tem) = 1; - return tem; + return fold_build1 (code, type, expr); } /* If TYPE is an enumeral type or a type with a precision less -- cgit v1.2.1