]> git.ipfire.org Git - thirdparty/gcc.git/commit
ada: Reset scope of top level object declaration during unnesting
authorMarc Poulhiès <poulhies@adacore.com>
Tue, 27 Feb 2024 12:47:27 +0000 (13:47 +0100)
committerMarc Poulhiès <poulhies@adacore.com>
Thu, 16 May 2024 08:49:34 +0000 (10:49 +0200)
commitf72988ac5ecfd56229374cbe76d867177ec5431d
treebfb3485ddbce6b4e1d40873954547c14d93ad97c
parent584ade0b82339d95463bc91c9fdd77579b16426a
ada: Reset scope of top level object declaration during unnesting

When unnesting, the compiler gathers elaboration code and wraps it with
a new dedicated procedure. While doing so, it resets the scopes of
entities that are wrapped to point to this new procedure. This change
also resets the scopes of N_Object_Declaration and
N_Object_Renaming_Declaration nodes only if an elaboration procedure
is needed.

gcc/ada/

* exp_ch7.adb (Reset_Scopes_To_Block_Elab_Proc): also reset scope
for object declarations.
gcc/ada/exp_ch7.adb