[Bug c/95580] [11 Regression] ICE in tree_strip_any_location_wrapper at gcc/tree.h:4011 since r11-959-gb825a22890740f34

cvs-commit at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Sun Jun 14 10:07:41 GMT 2020


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95580

--- Comment #5 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-10 branch has been updated by Jakub Jelinek
<jakub@gcc.gnu.org>:

https://gcc.gnu.org/g:b2229175b53e3b1c58b4aa963e3d0bb06ca063bf

commit r10-8297-gb2229175b53e3b1c58b4aa963e3d0bb06ca063bf
Author: Jakub Jelinek <jakub@redhat.com>
Date:   Tue Jun 9 08:39:36 2020 +0200

    c-family: Fix up MEM_REF printing [PR95580]

    The C FE in the MEM_REF printing ICEs if the type of the first argument
    (which due to useless pointer conversions can be an arbitrary type) is a
    pointer to an incomplete type.  The code just wants to avoid printing a
cast
    if it is a pointer to single byte elements.

    2020-06-09  Jakub Jelinek  <jakub@redhat.com>

            PR c/95580
            * c-pretty-print.c (c_pretty_printer::unary_expression): Handle the
            case when MEM_REF's first argument has type pointer to incomplete
type.

            * gcc.dg/pr95580.c: New test.

    (cherry picked from commit d6dbb71e468d0db561cc9eca99eeaca1efb81c11)


More information about the Gcc-bugs mailing list