+ -- Check again for configuration pragmas that appear in the context of
+ -- the main unit. These pragmas only affect the main unit, and the
+ -- corresponding flag is reset after each call to Semantics, but they
+ -- may affect the generated ali for the unit, and therefore the flag
+ -- must be set properly after compilation. Currently we only check for
+ -- Initialize_Scalars, but others should be checked: as well???
+
+ declare
+ Item : Node_Id;
+
+ begin
+ Item := First (Context_Items (Cunit (Main_Unit)));
+ while Present (Item) loop
+ if Nkind (Item) = N_Pragma
+ and then Pragma_Name (Item) = Name_Initialize_Scalars
+ then
+ Initialize_Scalars := True;
+ end if;
+
+ Next (Item);
+ end loop;
+ end;
+