Calling Semantics here will additionally update the reference to
Current_Sem_Unit the renamed unit so that we will not receive
bogus visibility errors when checking for self-referential with-s.
gcc/ada/ChangeLog:
* sem_ch10.adb(Analyze_With_Clause): Call Semantics instead
of Analyze to bring Current_Sem_Unit up to date.
-- the renamed unit, and the renaming declaration itself has not
-- been analyzed.
- Analyze (Parent (Parent (Entity (Pref))));
+ Semantics (Parent (Parent (Entity (Pref))));
pragma Assert (Renamed_Entity (Entity (Pref)) = Par_Name);
Par_Name := Entity (Pref);
end if;