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

--- Comment #9 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Eric Botcazou <[email protected]>:

https://gcc.gnu.org/g:476cfea758fa1240b5ae8bc25ac8eb0de06fff89

commit r16-4640-g476cfea758fa1240b5ae8bc25ac8eb0de06fff89
Author: Eric Botcazou <[email protected]>
Date:   Mon Oct 27 09:53:57 2025 +0100

    Ada: Fix segfault on mutually recursive record type declarations

    This was reported a long time ago and is again a fairly pathological case,
    but it turns out to be unfixable with the current model of type freezing
    in GNAT (which is the second one suggested in the AARM 13.14(19.i) clause).

    The code is legal but, as the declaration of any object of the types will
    exhaust the heap and eventually raise Storage_Error, it is totally useless.

    The patch contains a small cleanup in a related area as well as the
addition
    of a commented assertion in gigi, so that the compiler shuts down properly.

    gcc/ada/
            PR ada/15800
            * freeze.adb (Freeze_Entity.Freeze_Record_Type): Small cleanup
            in code and comments.
            * gcc-interface/utils.cc (create_field_decl): Assert that the type
            of the field is frozen at this point.
  • [Bug ada/15800] segfault on mut... cvs-commit at gcc dot gnu.org via Gcc-bugs

Reply via email to