[Ada] Crash/infinite loop on program with multiple visibility errors
This patch fixes the behavior of the compiler on a program with multiple
visibility errors. Previous to this fix the compiler would either crash
or enter an infinite loop on a declaration for the formal in a
subprogram declaration, when the parameter type was given by a selected
component that does not denote an entity. This patch also specializes
the error message when a local overloadable name has a homonym that is a
child package, which may containt an otherwise hidden interpreatation.
No simple reproducer.
2019-07-09 Ed Schonberg <schonberg@adacore.com>
gcc/ada/
* sem_ch4.adb (Diagnose_Call): Improve error recovery when a
local subprogram name hides a possible candidate name declared
in a child package in the context of the current unit.
* sem_ch6.adb (Process_Formals): Protect against malformed
formal types when the parameter type does not denote an entity.
From-SVN: r273289