]> git.ipfire.org Git - thirdparty/gcc.git/commit
[Ada] Inconsistent scope chain due to quantified expression
authorpmderodat <pmderodat@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 20 Aug 2019 09:50:34 +0000 (09:50 +0000)
committerpmderodat <pmderodat@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 20 Aug 2019 09:50:34 +0000 (09:50 +0000)
commit5c492d3cef3306fe70d60ddd735cfeaede3b69a2
treef37d5c3a6f0b8fce901af57d9357f99aef71d9f8
parent832af6f73f83cb8ecbf80b8425f654b92d7bb173
[Ada] Inconsistent scope chain due to quantified expression

Routine Build_DIC_Procedure_Declaration appears to be heavily inspired
by Build_Invariant_Procedure_Declaration; they both wrap an expression
attached to a type inside an internal procedure. Initially none of them
were calling Set_Last_Entity.

For Build_Invariant_Procedure_Declaration this was fixed previously.
For Build_DIC_Procedure_Declaration this is fixed here.

The issue affects the GNATprove tool and is not visible to end users of
the GNAT compiler. No simple test is available because this would
require a debug session.

2019-08-20  Piotr Trojanek  <trojanek@adacore.com>

gcc/ada/

* exp_util.adb (Build_DIC_Procedure_Declaration): Set the last
entity of the generated Default_Initial_Condition procedure in
order to construct a proper entity chain.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@274741 138bc75d-0d04-0410-961f-82ee72b054a4
gcc/ada/ChangeLog
gcc/ada/exp_util.adb