-- --
-- S p e c --
-- --
--- Copyright (C) 1997-2006, Free Software Foundation, Inc. --
+-- Copyright (C) 1997-2011, Free Software Foundation, Inc. --
-- --
-- GNAT is free software; you can redistribute it and/or modify it under --
-- terms of the GNU General Public License as published by the Free Soft- --
--- ware Foundation; either version 2, or (at your option) any later ver- --
+-- ware Foundation; either version 3, or (at your option) any later ver- --
-- sion. GNAT is distributed in the hope that it will be useful, but WITH- --
-- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY --
-- or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License --
-- for more details. You should have received a copy of the GNU General --
--- Public License distributed with GNAT; see file COPYING. If not, write --
--- to the Free Software Foundation, 51 Franklin Street, Fifth Floor, --
--- Boston, MA 02110-1301, USA. --
+-- Public License distributed with GNAT; see file COPYING3. If not, go to --
+-- http://www.gnu.org/licenses for a complete copy of the license. --
-- --
-- GNAT was originally developed by the GNAT team at New York University. --
-- Extensive contributions were provided by Ada Core Technologies Inc. --
-- Note on pragma Elaborate. The checking here assumes that a pragma
-- Elaborate on a with'ed unit guarantees that subprograms within the
-- unit can be called without causing an ABE. This is not in fact the
- -- case since pragma Elaborate does not guarantee the transititive
+ -- case since pragma Elaborate does not guarantee the transitive
-- coverage guaranteed by Elaborate_All. However, we leave this issue
-- up to the binder, which has generates warnings if there are possible
-- problems in the use of pragma Elaborate.
-- the resulting code does not contain subprogram specs with no
-- corresponding bodies.
- procedure Check_Elab_Call (N : Node_Id; Outer_Scope : Entity_Id := Empty);
+ procedure Check_Elab_Call
+ (N : Node_Id;
+ Outer_Scope : Entity_Id := Empty;
+ In_Init_Proc : Boolean := False);
-- Check a call for possible elaboration problems. The node N is either
-- an N_Function_Call or N_Procedure_Call_Statement node. The Outer_Scope
-- argument indicates whether this is an outer level call from Sem_Res
-- (Outer_Scope set to Empty), or an internal recursive call (Outer_Scope
- -- set to entity of outermost call, see body).
+ -- set to entity of outermost call, see body). Flag In_Init_Proc should be
+ -- set whenever the current context is a type init proc.
procedure Check_Elab_Calls;
-- Not all the processing for Check_Elab_Call can be done at the time