Commit 3e5daac4 by Arnaud Charlet

[multiple changes]

2010-10-26  Vincent Celier  <celier@adacore.com>

	* prj.ads (Source_Data): New Boolean component Initialized, defaulted
	to False, set to True when Source_Data is completely initialized.
	* prj-env.adb: Minor comment fix.

2010-10-26  Robert Dewar  <dewar@adacore.com>

	* sem_case.adb, sem_ch6.adb, sem_util.adb: Minor reformatting.

From-SVN: r165943
parent 232b0794
2010-10-26 Vincent Celier <celier@adacore.com>
* prj.ads (Source_Data): New Boolean component Initialized, defaulted
to False, set to True when Source_Data is completely initialized.
* prj-env.adb: Minor comment fix.
2010-10-26 Robert Dewar <dewar@adacore.com>
* sem_case.adb, sem_ch6.adb, sem_util.adb: Minor reformatting.
2010-10-26 Ed Schonberg <schonberg@adacore.com>
* sem_ch5.adb (Analyze_Iteration_Scheme): Diagnose attempt to use thew
......
......@@ -2084,7 +2084,7 @@ package body Prj.Env is
Has_Dot : Boolean := False;
Key : Name_Id;
-- Start of processing for Project_Path_Name_Of
-- Start of processing for Find_Project
begin
Initialize_Project_Path (Self, "");
......
......@@ -663,6 +663,9 @@ package Prj is
-- Structure to define source data
type Source_Data is record
Initialized : Boolean := False;
-- Set to True when Source_Data is completely initialized
Project : Project_Id := No_Project;
-- Project of the source
......@@ -784,7 +787,8 @@ package Prj is
end record;
No_Source_Data : constant Source_Data :=
(Project => No_Project,
(Initialized => False,
Project => No_Project,
Location => No_Location,
Source_Dir_Rank => 0,
Language => No_Language_Index,
......
......@@ -313,9 +313,9 @@ package body Sem_Case is
Hi := Expr_Value (Choice_Table (J).Hi);
if Lo <= Prev_Hi then
Choice := Choice_Table (J).Node;
Choice := Choice_Table (J).Node;
-- Find first previous choice that overlaps.
-- Find first previous choice that overlaps
for K in 1 .. J - 1 loop
if Lo <= Expr_Value (Choice_Table (K).Hi) then
......
......@@ -2326,12 +2326,24 @@ package body Sem_Ch6 is
-- Case of subprogram body with no previous spec
else
-- Check for style warning required
if Style_Check
-- Only apply check for source level subprograms for which checks
-- have not been suppressed.
and then Comes_From_Source (Body_Id)
and then not Suppress_Style_Checks (Body_Id)
-- No warnings within an instance
and then not In_Instance
and then Nkind (Original_Node (Body_Id))
/= N_Parameterized_Expression
-- No warnings for parameterized expressions
and then Nkind (Original_Node (Body_Id)) /=
N_Parameterized_Expression
then
Style.Body_With_No_Spec (N);
end if;
......
......@@ -5122,6 +5122,7 @@ package body Sem_Util is
-- We are interested only in components and discriminants
Exp := Empty;
case Ekind (Ent) is
when E_Component =>
......@@ -5145,7 +5146,6 @@ package body Sem_Util is
when others =>
goto Check_Next_Entity;
end case;
-- A component has PI if it has no default expression and the
......
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