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

--- Comment #4 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Marek Polacek <mpola...@gcc.gnu.org>:

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

commit r10-7568-gf84aded848f6fdd2704c9376263c6d1aee6bb0ca
Author: Marek Polacek <pola...@redhat.com>
Date:   Mon Mar 30 15:49:17 2020 -0400

    c++: Fix crash in gimplifier with paren init of aggregates [PR94155]

    Here we crash in the gimplifier because gimplify_init_ctor_eval doesn't
    expect null indexes for a constructor:

          /* ??? Here's to hoping the front end fills in all of the indices,
             so we don't have to figure out what's missing ourselves.  */
          gcc_assert (purpose);

    The indexes weren't filled because we never called reshape_init: for
    a constructor that represents parenthesized initialization of an
    aggregate we don't allow brace elision or designated initializers.

            PR c++/94155 - crash in gimplifier with paren init of aggregates.
            * init.c (build_vec_init): Fill in indexes.

            * g++.dg/cpp2a/paren-init22.C: New test.

Reply via email to