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

--- Comment #4 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:2e1284494952d777178386b50048d0d89fa7bb00

commit r16-8307-g2e1284494952d777178386b50048d0d89fa7bb00
Author: Eric Botcazou <[email protected]>
Date:   Fri Mar 27 18:38:09 2026 +0100

    Ada: Fix overriding indicator wrongly rejected on protected procedure

    The case itself is fairly pathological (and very likely not human made),
but
    it's a clear incentive to get rid of an old kludge in generic
instantiation,
    whereby the full view of a type is forced on nodes in the generic unit even
    though only the partial declaration is visible to them.

    gcc/ada/
            PR ada/124596
            * sem_ch12.ads (Check_Private_View): Move around.
            * sem_ch12.adb (Check_Private_View): Retrieve the partial view
            by means of a call to Incomplete_Or_Partial_View.
            (Save_Global_References.Set_Global_Type): Do not force the full
            view of a type when only the partial declaration is visible.
            * sem_res.adb (Resolve_Actuals.Insert_Default): Remove obsolete
            code coping with the above kludge.

    gcc/testsuite/
            * gnat.dg/generic_inst21.adb: New test.

Reply via email to