Commit 65b03d7d by Ed Schonberg Committed by Arnaud Charlet

sem_elab.adb (Check_Elab_Call): Do not check a call that does not appear in the…

sem_elab.adb (Check_Elab_Call): Do not check a call that does not appear in the code for the main unit.

2004-10-26  Ed Schonberg  <schonberg@gnat.com>

	* sem_elab.adb (Check_Elab_Call): Do not check a call that does not
	appear in the code for the main unit. Dependencies among units in the
	context of the main unit are established when those other units are
	compiled. Otherwise spurious elaboration constraints can generate
	incorrect elaboration circularities.

From-SVN: r89673
parent e895b435
......@@ -913,6 +913,14 @@ package body Sem_Elab is
-- Start of processing for Check_Elab_Call
begin
-- If the call does not come from the main unit, there is nothing to
-- check. Elaboration call from units in the context of the main unit
-- will lead to semantic dependencies when those units are compiled.
if not In_Extended_Main_Code_Unit (N) then
return;
end if;
-- For an entry call, check relevant restriction
if Nkind (N) = N_Entry_Call_Statement
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment