[Ada] Spurious visibility error on Declare_Expression with renames
authorEd Schonberg <schonberg@adacore.com>
Thu, 25 Jun 2020 20:44:27 +0000 (16:44 -0400)
committerPierre-Marie de Rodat <derodat@adacore.com>
Fri, 16 Oct 2020 07:31:25 +0000 (03:31 -0400)
commita121d54f7b59cbb424f707acd587adba4ad265d4
tree0910cc2b31430f4197335ab808a786a8958bf178
parentf54147fcfd885598d57783f98b0786e9e200a5dc
[Ada] Spurious visibility error on Declare_Expression with renames

gcc/ada/

* sem_res.adb (Resolve_Declare_Expression): Retrieve the created
block entity that is the scope of the local declarations, from
either a local object declaration or an object renaming
declaration. The block entity does not have an explicit
declaration, but appears as the scope of all locally declared
objects.
gcc/ada/sem_res.adb