Commit 800621e0 by Robert Dewar Committed by Arnaud Charlet

inline.adb (Back_End_Cannot_Inline): Use new flag Has_Pragma_Inline_Always…

inline.adb (Back_End_Cannot_Inline): Use new flag Has_Pragma_Inline_Always instead of obsolete function Is_Always_Inlined

2007-12-06  Robert Dewar  <dewar@adacore.com>

	* inline.adb (Back_End_Cannot_Inline): Use new flag
	Has_Pragma_Inline_Always instead of obsolete function Is_Always_Inlined

	* sem_ch6.ads, sem_ch6.adb (Analyze_Subprogram_Body): Use new flag
	Has_Pragma_Inline_Always instead.
	of obsolete function Is_Always_Inlined
	(Build_Body_To_Inline): Same change
	(Cannot_Inline): Same change
	Do not give warning on exception raise in No_Return function

	* sem_ch13.adb (Analyze_Record_Representation_Clause): If an inherited
	component has two inconsistent component clauses in the same record
	representation clause, favor the message that complains about
	duplication rather than inconsistency.
	Update comments.
	(Record_Representation_Clause): Do not warn on missing component
	clauses for inherited components of a type extension.
	(Rep_Item_Too_Late): Do not attempt to link pragma into rep chain for
	an overloadable item if it is a pragma that can apply to multiple
	overloadable entities (e.g. Inline) because a pragma cannot be on
	more than one chain at a time.
	(Validate_Unchecked_Conversion): Add code to warn on unchecked
	conversion where one of the operands is Ada.Calendar.Time.
	(Analyze_Attribute_Definition_Clause): Fix typo in error message.
	For now, ignore Component_Size clause on VM targets, as done for
	pragma Pack.

From-SVN: r130845
parent fcedf218
...@@ -393,7 +393,7 @@ package body Inline is ...@@ -393,7 +393,7 @@ package body Inline is
-- If subprogram is marked Inline_Always, inlining is mandatory -- If subprogram is marked Inline_Always, inlining is mandatory
if Is_Always_Inlined (Subp) then if Has_Pragma_Inline_Always (Subp) then
return False; return False;
end if; end if;
...@@ -726,7 +726,7 @@ package body Inline is ...@@ -726,7 +726,7 @@ package body Inline is
E := First_Entity (P); E := First_Entity (P);
while Present (E) loop while Present (E) loop
if Is_Always_Inlined (E) if Has_Pragma_Inline_Always (E)
or else (Front_End_Inlining and then Has_Pragma_Inline (E)) or else (Front_End_Inlining and then Has_Pragma_Inline (E))
then then
if not Is_Loaded (Bname) then if not Is_Loaded (Bname) then
......
...@@ -176,6 +176,16 @@ package Sem_Ch6 is ...@@ -176,6 +176,16 @@ package Sem_Ch6 is
-- access parameter are attached to the Related_Nod which comes from the -- access parameter are attached to the Related_Nod which comes from the
-- context. -- context.
procedure Reference_Body_Formals (Spec : Entity_Id; Bod : Entity_Id);
-- If there is a separate spec for a subprogram or generic subprogram, the
-- formals of the body are treated as references to the corresponding
-- formals of the spec. This reference does not count as an actual use of
-- the formal, in order to diagnose formals that are unused in the body.
-- This procedure is also used in renaming_as_body declarations, where
-- the formals of the specification must be treated as body formals that
-- correspond to the previous subprogram declaration, and not as new
-- entities with their defining entry in the cross-reference information.
procedure Set_Actual_Subtypes (N : Node_Id; Subp : Entity_Id); procedure Set_Actual_Subtypes (N : Node_Id; Subp : Entity_Id);
-- If the formals of a subprogram are unconstrained, build a subtype -- If the formals of a subprogram are unconstrained, build a subtype
-- declaration that uses the bounds or discriminants of the actual to -- declaration that uses the bounds or discriminants of the actual to
......
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