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

--- Comment #3 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-10 branch has been updated by Iain Buclaw
<ibuc...@gcc.gnu.org>:

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

commit r10-11485-ga44fb702058974cc7592e8f8a81260f6ab35bece
Author: Iain Buclaw <ibuc...@gdcproject.org>
Date:   Sat Jul 1 15:04:25 2023 +0200

    d: Fix ICE in setValue, at d/dmd/dinterpret.c:7013

    Backports ICE fix from upstream.  When casting null to integer or real,
    instead of painting the type on the NullExp, we emplace an
    IntegerExp/RealExp with the value zero.  Same as when casting from
    NullExp to bool.

    Reviewed-on: https://github.com/dlang/dmd/pull/13172

            PR d/110511

    gcc/d/ChangeLog:

            * dmd/dinterpret.c (Interpreter::visit (CastExp *)): Handle casting
            null to int or float.

    gcc/testsuite/ChangeLog:

            * gdc.test/compilable/test21794.d: New test.

    (cherry picked from commit 066385c918485d4cef5c243d3b0691193df382de)

Reply via email to