re PR middle-end/89210 (ICE tree check: expected integer_cst, have real_cst in to_wid...
authorJakub Jelinek <jakub@redhat.com>
Wed, 6 Feb 2019 09:16:19 +0000 (10:16 +0100)
committerJakub Jelinek <jakub@gcc.gnu.org>
Wed, 6 Feb 2019 09:16:19 +0000 (10:16 +0100)
commit4763581763de6049c938ea7129d738d497004a06
tree36db92da41720345c8b90ec4dd599bb527a46a17
parentce4321c918aa0d17ecd7da6c3deb43524b1729cf
re PR middle-end/89210 (ICE tree check: expected integer_cst, have real_cst in to_wide, at tree.h:5600)

PR middle-end/89210
* fold-const-call.c (fold_const_vec_convert): Pass true as last
operand to new_unary_operation only if both element types are integral
and it isn't a widening conversion.  Return NULL_TREE if
new_unary_operation failed.

* c-c++-common/builtin-convertvector-2.c: New test.

From-SVN: r268573
gcc/ChangeLog
gcc/fold-const-call.c
gcc/testsuite/ChangeLog
gcc/testsuite/c-c++-common/builtin-convertvector-2.c [new file with mode: 0644]