aboutsummaryrefslogtreecommitdiff
path: root/gcc/ada/sem_ch7.ads
diff options
context:
space:
mode:
authorArnaud Charlet <charlet@gcc.gnu.org>2016-04-21 11:46:18 +0200
committerArnaud Charlet <charlet@gcc.gnu.org>2016-04-21 11:46:18 +0200
commit22a4f9d54db67a17191dfad5dfb635465489be8c (patch)
treedf2aa9b9f66c3d60d3ad578b000ee3ac83c7f466 /gcc/ada/sem_ch7.ads
parentc4dc2125063be04a54d030075a03e4ded7be38d5 (diff)
downloadgcc-22a4f9d54db67a17191dfad5dfb635465489be8c.zip
gcc-22a4f9d54db67a17191dfad5dfb635465489be8c.tar.gz
gcc-22a4f9d54db67a17191dfad5dfb635465489be8c.tar.bz2
[multiple changes]
2016-04-21 Jerome Lambourg <lambourg@adacore.com> * s-soflin.adb: Initialize the Stack_Limit global variable. 2016-04-21 Hristian Kirtchev <kirtchev@adacore.com> * lib-writ.adb: Minor reformatting. 2016-04-21 Ed Schonberg <schonberg@adacore.com> * exp_pakd.adb (Compute_Number_Components): New function to build an expression that computes the number of a components of an array that may be multidimensional. (Expan_Packed_Eq): Use it. 2016-04-21 Arnaud Charlet <charlet@adacore.com> * g-traceb.ads: Update list of supported platforms. 2016-04-21 Ed Schonberg <schonberg@adacore.com> * sem_ch13.adb (Add_Predicates): if the type is declared in an inner package it may be frozen outside of the package, and the generated pragma has not been analyzed yet, the expression for the predicate must be captured and added to the predicate function at this point. 2016-04-21 Hristian Kirtchev <kirtchev@adacore.com> * contracts.adb (Analyze_Package_Body_Contract): Do not check for a missing package refinement because 1) packages do not have "refinement" and 2) the check for proper state refinement is performed in a different place. * einfo.adb (Has_Non_Null_Visible_Refinement): Reimplemented. (Has_Null_Visible_Refinement): Reimplemented. * sem_ch3.adb (Analyze_Declarations): Determine whether all abstract states have received a refinement and if not, emit errors. * sem_ch7.adb (Analyze_Package_Declaration): Code cleanup. Determine whether all abstract states of the package and any nested packages have received a refinement and if not, emit errors. (Requires_Completion_In_Body): Add new formal parameter Do_Abstract_States. Update the comment on usage. Propagate the Do_Abstract_States flag to all Unit_Requires_Body calls. (Unit_Requires_Body): Remove formal parameter Ignore_Abstract_States. Add new formal paramter Do_Abstract_States. Propagate the Do_Abstract_States flag to all Requires_Completion_In calls. * sem_ch7.ads (Unit_Requires_Body): Remove formal parameter Ignore_Abstract_States. Add new formal paramter Do_Abstract_States. Update the comment on usage. * sem_ch9.adb (Analyze_Single_Protected_Declaration): Do not initialize the constituent list as this is now done on a need-to-add-element basis. (Analyze_Single_Task_Declaration): Do not initialize the constituent list as this is now done on a need-to-add-element basis. * sem_ch10.adb (Decorate_State): Do not initialize the constituent lists as this is now done on a need-to-add-element basis. * sem_prag.adb (Analyze_Constituent): Set the refinement constituents when adding a new element. (Analyze_Part_Of_In_Decl_Part): Set the Part_Of constituents when adding a new element. (Analyze_Part_Of_Option): Set the Part_Of constituents when adding a new element. (Analyze_Pragma): Set the Part_Of constituents when adding a new element. (Check_Constituent_Usage (all versions)): Reimplemented. (Collect_Constituent): Set the refinement constituents when adding a new element. (Create_Abstract_State): Do not initialize the constituent lists as this is now done on a need-to-add-element basis. (Propagate_Part_Of): Set the Part_Of constituents when adding a new element. * sem_util.adb (Check_State_Refinements): New routine. (Has_Non_Null_Refinement): Reimplemented. (Has_Null_Refinement): Reimplemented. (Requires_State_Refinement): Removed. * sem_util.ads (Check_State_Refinements): New routine. (Requires_State_Refinement): Removed. From-SVN: r235326
Diffstat (limited to 'gcc/ada/sem_ch7.ads')
-rw-r--r--gcc/ada/sem_ch7.ads15
1 files changed, 6 insertions, 9 deletions
diff --git a/gcc/ada/sem_ch7.ads b/gcc/ada/sem_ch7.ads
index 59f27b0..2963aed 100644
--- a/gcc/ada/sem_ch7.ads
+++ b/gcc/ada/sem_ch7.ads
@@ -6,7 +6,7 @@
-- --
-- S p e c --
-- --
--- Copyright (C) 1992-2015, Free Software Foundation, Inc. --
+-- Copyright (C) 1992-2016, 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- --
@@ -53,17 +53,14 @@ package Sem_Ch7 is
-- child for public child packages.
function Unit_Requires_Body
- (Pack_Id : Entity_Id;
- Ignore_Abstract_State : Boolean := False) return Boolean;
+ (Pack_Id : Entity_Id;
+ Do_Abstract_States : Boolean := False) return Boolean;
-- Determine whether package Pack_Id requires a body. A specification needs
-- a body if it contains declarations that require completion in the body.
-- A non-Ghost [generic] package does not require a body when it declares
- -- Ghost entities exclusively. If flag Ignore_Abstract_State is True, then
- -- the test for a non-null abstract state (which normally requires a body)
- -- is not carried out. The flag is not currently used, but may be useful
- -- in the future if we implement a compatibility mode which warns about
- -- possible incompatibilities if a SPARK 2014 program is compiled with a
- -- SPARK-unaware compiler.
+ -- Ghost entities exclusively. When flag Do_Abstract_States is set to True,
+ -- non-null abstract states are considered in determining the need for a
+ -- body.
procedure May_Need_Implicit_Body (E : Entity_Id);
-- If a package declaration contains tasks or RACWs and does not require