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

            Bug ID: 124143
           Summary: AI12-0331 not correctly implemented
           Product: gcc
           Version: 15.2.1
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: ada
          Assignee: unassigned at gcc dot gnu.org
          Reporter: liam at liampwll dot com
                CC: dkm at gcc dot gnu.org
  Target Milestone: ---

Created attachment 63704
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=63704&action=edit
fix

This is a very minor issue that I came across while improving ACATS subpool
coverage but it's also very easy to fix. AI12-0331 changed the ordering of
Unchecked_Deallocate_Subpool such that the subpool still belongs to the pool at
the time that the call to Deallocate_Subpool is made. This is visible within
Deallocate_Subpool as it is legal to call Pool_of_Subpool from inside it.

This is extremely trivial to fix as shown in the attached diff. Perhaps
Subpool.Owner should still be set to null if Deallocate_Subpool raises an
exception but the RM does not give clear guidance on that.

Reply via email to