ada: Fix for quantified expressions in Exceptional_Cases
commit86f03e37d6e5b601e663b9339aacb9bd22d7d4b4
authorPiotr Trojanek <trojanek@adacore.com>
Thu, 1 Jun 2023 07:59:40 +0000 (1 09:59 +0200)
committerMarc Poulhiès <poulhies@adacore.com>
Tue, 20 Jun 2023 07:30:49 +0000 (20 09:30 +0200)
treed7ffda95f08b9d765057b690c3d5b602f29ac3b6
parent970ee828e75fb3f67a7dc8dd8108e9a2f23b997b
ada: Fix for quantified expressions in Exceptional_Cases

When detecting illegal uses of formal parameters of the current
subprogram in contract of its Exceptional_Cases, we relied on the
Current_Scope. However, quantified expressions introduce an implicit
scope, which we need to take into account.

gcc/ada/

* sem_res.adb (Resolve_Entity_Name): Ignore implicit loop scopes
introduced by quantified expressions.
gcc/ada/sem_res.adb