-- Start of processing for Check_Dependency_Clause
begin
- -- Do not perform this check in an instance because it was already
- -- performed successfully in the generic template.
-
- if In_Instance then
- return;
- end if;
-
-- Examine all refinement clauses and compare them against the
-- dependence clause.
-- Start of processing for Check_Output_States
begin
- -- Do not perform this check in an instance because it was already
- -- performed successfully in the generic template.
-
- if In_Instance then
- null;
-
-- Inspect the outputs of pragma Depends looking for a state with a
-- visible refinement.
- elsif Present (Spec_Outputs) then
+ if Present (Spec_Outputs) then
Item_Elmt := First_Elmt (Spec_Outputs);
while Present (Item_Elmt) loop
Item := Node (Item_Elmt);
Clause : Node_Id;
begin
- -- Do not perform this check in an instance because it was already
- -- performed successfully in the generic template.
-
- if In_Instance then
- null;
-
- elsif Present (Clauses) then
+ if Present (Clauses) then
Clause := First (Clauses);
while Present (Clause) loop
SPARK_Msg_N
Analyze_Depends_In_Decl_Part (N);
+ -- Do not perform these checks in an instance because they were already
+ -- performed successfully in the generic template.
+
+ if In_Instance then
+ goto Leave;
+ end if;
+
-- Do not match dependencies against refinements if Refined_Depends is
-- illegal to avoid emitting misleading error.