Commit 2598ee6d by Robert Dewar Committed by Arnaud Charlet

bindgen.adb, [...]: Minor reformatting

2011-08-04  Robert Dewar  <dewar@adacore.com>

	* bindgen.adb, einfo.adb, sem_ch12.adb, s-tasren.adb, sem_res.adb,
	makeutl.adb, prj-nmsc.adb, opt.ads, prj-env.adb: Minor reformatting
	* gcc-interface/Make-lang.in: Update dependencies.

From-SVN: r177356
parent c2db4b32
2011-08-04 Robert Dewar <dewar@adacore.com>
* bindgen.adb, einfo.adb, sem_ch12.adb, s-tasren.adb, sem_res.adb,
makeutl.adb, prj-nmsc.adb, opt.ads, prj-env.adb: Minor reformatting
* gcc-interface/Make-lang.in: Update dependencies.
2011-08-04 Arnaud Charlet <charlet@adacore.com> 2011-08-04 Arnaud Charlet <charlet@adacore.com>
* prj-env.adb: Remove local debug traces. * prj-env.adb: Remove local debug traces.
......
...@@ -2219,11 +2219,15 @@ package body Bindgen is ...@@ -2219,11 +2219,15 @@ package body Bindgen is
WBI (" Break_Start;"); WBI (" Break_Start;");
if CodePeer_Mode then if CodePeer_Mode then
-- Bypass Ada_Main_Program; its Import pragma confuses CodePeer.
-- Bypass Ada_Main_Program, its Import pragma confuses CodePeer
Get_Name_String (Units.Table (First_Unit_Entry).Uname); Get_Name_String (Units.Table (First_Unit_Entry).Uname);
declare declare
Callee_Name : String renames Name_Buffer (1 .. Name_Len - 2); Callee_Name : String renames Name_Buffer (1 .. Name_Len - 2);
-- strip trailing "%b" -- Strip trailing "%b"
begin begin
if ALIs.Table (ALIs.First).Main_Program = Proc then if ALIs.Table (ALIs.First).Main_Program = Proc then
WBI (" " & Callee_Name & ";"); WBI (" " & Callee_Name & ";");
...@@ -2231,8 +2235,10 @@ package body Bindgen is ...@@ -2231,8 +2235,10 @@ package body Bindgen is
WBI (" Result := " & Callee_Name & ";"); WBI (" Result := " & Callee_Name & ";");
end if; end if;
end; end;
elsif ALIs.Table (ALIs.First).Main_Program = Proc then elsif ALIs.Table (ALIs.First).Main_Program = Proc then
WBI (" Ada_Main_Program;"); WBI (" Ada_Main_Program;");
else else
WBI (" Result := Ada_Main_Program;"); WBI (" Result := Ada_Main_Program;");
end if; end if;
...@@ -3076,10 +3082,14 @@ package body Bindgen is ...@@ -3076,10 +3082,14 @@ package body Bindgen is
end if; end if;
if CodePeer_Mode then if CodePeer_Mode then
-- For CodePeer, main program is not called via an Import pragma.
-- For CodePeer, main program is not called via an Import pragma
Get_Name_String (Units.Table (First_Unit_Entry).Uname); Get_Name_String (Units.Table (First_Unit_Entry).Uname);
-- Note: trailing "%b" is stripped.
WBI ("with " & Name_Buffer (1 .. Name_Len - 2) & ";"); WBI ("with " & Name_Buffer (1 .. Name_Len - 2) & ";");
-- strip trailing "%b"
end if; end if;
WBI (""); WBI ("");
...@@ -3088,6 +3098,7 @@ package body Bindgen is ...@@ -3088,6 +3098,7 @@ package body Bindgen is
WBI (""); WBI ("");
-- Generate externals for elaboration entities -- Generate externals for elaboration entities
Gen_Elab_Externals_Ada; Gen_Elab_Externals_Ada;
if not Suppress_Standard_Library_On_Target then if not Suppress_Standard_Library_On_Target then
......
...@@ -409,7 +409,6 @@ package body Einfo is ...@@ -409,7 +409,6 @@ package body Einfo is
-- Is_Compilation_Unit Flag149 -- Is_Compilation_Unit Flag149
-- Has_Pragma_Elaborate_Body Flag150 -- Has_Pragma_Elaborate_Body Flag150
-- (unused) Flag151
-- Entry_Accepted Flag152 -- Entry_Accepted Flag152
-- Is_Obsolescent Flag153 -- Is_Obsolescent Flag153
-- Has_Per_Object_Constraint Flag154 -- Has_Per_Object_Constraint Flag154
...@@ -519,9 +518,11 @@ package body Einfo is ...@@ -519,9 +518,11 @@ package body Einfo is
-- Is_Safe_To_Reevaluate Flag249 -- Is_Safe_To_Reevaluate Flag249
-- Has_Predicates Flag250 -- Has_Predicates Flag250
-- (unused) Flag251
-- Is_Processed_Transient Flag252 -- Is_Processed_Transient Flag252
-- Is_Postcondition_Proc Flag253 -- Is_Postcondition_Proc Flag253
-- (unused) Flag151
-- (unused) Flag251
-- (unused) Flag254 -- (unused) Flag254
----------------------- -----------------------
......
...@@ -1301,8 +1301,9 @@ ada/alfa.o : ada/ada.ads ada/a-except.ads ada/a-unccon.ads \ ...@@ -1301,8 +1301,9 @@ ada/alfa.o : ada/ada.ads ada/a-except.ads ada/a-unccon.ads \
ada/aspects.ads ada/atree.ads ada/atree.adb ada/casing.ads \ ada/aspects.ads ada/atree.ads ada/atree.adb ada/casing.ads \
ada/debug.ads ada/einfo.ads ada/gnat.ads ada/g-htable.ads \ ada/debug.ads ada/einfo.ads ada/gnat.ads ada/g-htable.ads \
ada/g-table.ads ada/g-table.adb ada/hostparm.ads ada/interfac.ads \ ada/g-table.ads ada/g-table.adb ada/hostparm.ads ada/interfac.ads \
ada/namet.ads ada/namet.adb ada/nlists.ads ada/nlists.adb ada/opt.ads \ ada/namet.ads ada/namet.adb ada/nlists.ads ada/nlists.adb \
ada/output.ads ada/output.adb ada/put_alfa.ads ada/put_alfa.adb \ ada/nmake.ads ada/opt.ads ada/output.ads ada/output.adb \
ada/put_alfa.ads ada/put_alfa.adb ada/sem_util.ads \
ada/sinfo.ads ada/sinfo.adb ada/sinput.ads ada/snames.ads \ ada/sinfo.ads ada/sinfo.adb ada/sinput.ads ada/snames.ads \
ada/system.ads ada/s-exctab.ads ada/s-htable.ads ada/s-imenne.ads \ ada/system.ads ada/s-exctab.ads ada/s-htable.ads ada/s-imenne.ads \
ada/s-memory.ads ada/s-os_lib.ads ada/s-parame.ads ada/s-secsta.ads \ ada/s-memory.ads ada/s-os_lib.ads ada/s-parame.ads ada/s-secsta.ads \
...@@ -3322,10 +3323,10 @@ ada/put_alfa.o : ada/ada.ads ada/a-except.ads ada/a-unccon.ads \ ...@@ -3322,10 +3323,10 @@ ada/put_alfa.o : ada/ada.ads ada/a-except.ads ada/a-unccon.ads \
ada/unchconv.ads ada/unchdeal.ads ada/urealp.ads ada/unchconv.ads ada/unchdeal.ads ada/urealp.ads
ada/put_scos.o : ada/ada.ads ada/a-unccon.ads ada/gnat.ads ada/g-table.ads \ ada/put_scos.o : ada/ada.ads ada/a-unccon.ads ada/gnat.ads ada/g-table.ads \
ada/g-table.adb ada/put_scos.ads ada/put_scos.adb ada/scos.ads \ ada/g-table.adb ada/par_sco.ads ada/put_scos.ads ada/put_scos.adb \
ada/scos.adb ada/system.ads ada/s-exctab.ads ada/s-memory.ads \ ada/scos.ads ada/scos.adb ada/system.ads ada/s-exctab.ads \
ada/s-stalib.ads ada/s-unstyp.ads ada/types.ads ada/unchconv.ads \ ada/s-memory.ads ada/s-stalib.ads ada/s-unstyp.ads ada/types.ads \
ada/unchdeal.ads ada/unchconv.ads ada/unchdeal.ads
ada/repinfo.o : ada/ada.ads ada/a-except.ads ada/a-unccon.ads \ ada/repinfo.o : ada/ada.ads ada/a-except.ads ada/a-unccon.ads \
ada/a-uncdea.ads ada/alloc.ads ada/aspects.ads ada/atree.ads \ ada/a-uncdea.ads ada/alloc.ads ada/aspects.ads ada/atree.ads \
......
...@@ -328,7 +328,7 @@ package Opt is ...@@ -328,7 +328,7 @@ package Opt is
-- of withing a package and using none of the entities in the package. -- of withing a package and using none of the entities in the package.
CodePeer_Mode : Boolean := False; CodePeer_Mode : Boolean := False;
-- GNAT -- GNAT, GNATBIND
-- Enable full CodePeer mode (SCIL generation, disable switches that -- Enable full CodePeer mode (SCIL generation, disable switches that
-- interact badly with it, etc...). -- interact badly with it, etc...).
......
...@@ -476,7 +476,7 @@ package body Prj.Env is ...@@ -476,7 +476,7 @@ package body Prj.Env is
File_Name : Path_Name_Type := No_Path; File_Name : Path_Name_Type := No_Path;
File : File_Descriptor := Invalid_FD; File : File_Descriptor := Invalid_FD;
Current_Naming : Naming_Id; Current_Naming : Naming_Id;
procedure Check procedure Check
(Project : Project_Id; (Project : Project_Id;
......
...@@ -1101,17 +1101,17 @@ package body System.Tasking.Rendezvous is ...@@ -1101,17 +1101,17 @@ package body System.Tasking.Rendezvous is
-- We rely that the call is off-queue for protection, that the caller -- We rely that the call is off-queue for protection, that the caller
-- will not exit the Entry_Caller_Sleep, and so will not reuse the call -- will not exit the Entry_Caller_Sleep, and so will not reuse the call
-- record for another call. -- record for another call. We rely on the Caller's lock for call State
-- We rely on the Caller's lock for call State mod's. -- mod's.
-- If Acceptor.Terminate_Alternative is True, we need to lock Parent and -- If Acceptor.Terminate_Alternative is True, we need to lock Parent and
-- Acceptor, in that order; otherwise, we only need a lock on -- Acceptor, in that order; otherwise, we only need a lock on Acceptor.
-- Acceptor. However, we can't check Acceptor.Terminate_Alternative -- However, we can't check Acceptor.Terminate_Alternative until Acceptor
-- until Acceptor is locked. Therefore, we need to lock both. Attempts -- is locked. Therefore, we need to lock both. Attempts to avoid locking
-- to avoid locking Parent tend to result in race conditions. It would -- Parent tend to result in race conditions. It would work to unlock
-- work to unlock Parent immediately upon finding -- Parent immediately upon finding Acceptor.Terminate_Alternative to be
-- Acceptor.Terminate_Alternative to be False, but that violates the -- False, but that violates the rule of properly nested locking (see
-- rule of properly nested locking (see System.Tasking). -- System.Tasking).
STPO.Write_Lock (Parent); STPO.Write_Lock (Parent);
STPO.Write_Lock (Acceptor); STPO.Write_Lock (Acceptor);
......
...@@ -6919,6 +6919,7 @@ package body Sem_Ch12 is ...@@ -6919,6 +6919,7 @@ package body Sem_Ch12 is
-- simplified. ??? -- simplified. ???
Inst := Package_Instantiation (A); Inst := Package_Instantiation (A);
if Present (Inst) then if Present (Inst) then
if Nkind (Inst) = N_Package_Instantiation then if Nkind (Inst) = N_Package_Instantiation then
return Inst; return Inst;
...@@ -7138,8 +7139,8 @@ package body Sem_Ch12 is ...@@ -7138,8 +7139,8 @@ package body Sem_Ch12 is
-- that we produce all the instance bodies we will need. -- that we produce all the instance bodies we will need.
if (Is_Entity_Name (Nam) and then Chars (Nam) = Chars (E)) if (Is_Entity_Name (Nam) and then Chars (Nam) = Chars (E))
or else (Nkind (Nam) = N_Selected_Component or else (Nkind (Nam) = N_Selected_Component
and then Chars (Selector_Name (Nam)) = Chars (E)) and then Chars (Selector_Name (Nam)) = Chars (E))
then then
return True; return True;
end if; end if;
......
...@@ -7248,6 +7248,7 @@ package body Sem_Res is ...@@ -7248,6 +7248,7 @@ package body Sem_Res is
declare declare
Left_Typ : constant Node_Id := Etype (Left_Opnd (N)); Left_Typ : constant Node_Id := Etype (Left_Opnd (N));
Right_Typ : constant Node_Id := Etype (Right_Opnd (N)); Right_Typ : constant Node_Id := Etype (Right_Opnd (N));
begin begin
-- Protect call to Matching_Static_Array_Bounds to avoid costly -- Protect call to Matching_Static_Array_Bounds to avoid costly
-- operation if not needed. -- operation if not needed.
......
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