Commit d3ba478e by Arnaud Charlet

[multiple changes]

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

	* gnat_rm.texi: Minor change.
	* exp_attr_light.adb: Minor reformatting.

2011-08-30  Ed Schonberg  <schonberg@adacore.com>

	* sem_ch3.adb: Patch inheritance of aspects in
	Complete_Private_Subtype, to avoid infinite loop.

From-SVN: r178305
parent c01817d2
2011-08-30 Robert Dewar <dewar@adacore.com>
* gnat_rm.texi: Minor change.
* exp_attr_light.adb: Minor reformatting.
2011-08-30 Ed Schonberg <schonberg@adacore.com>
* sem_ch3.adb: Patch inheritance of aspects in
Complete_Private_Subtype, to avoid infinite loop.
2011-08-30 Javier Miranda <miranda@adacore.com> 2011-08-30 Javier Miranda <miranda@adacore.com>
* sem_ch3.adb (Add_Internal_Interface_Entities): If serious errors have * sem_ch3.adb (Add_Internal_Interface_Entities): If serious errors have
......
...@@ -35,10 +35,11 @@ package body Exp_Attr_Light is ...@@ -35,10 +35,11 @@ package body Exp_Attr_Light is
procedure Expand_Light_N_Attribute_Reference (N : Node_Id) is procedure Expand_Light_N_Attribute_Reference (N : Node_Id) is
Id : constant Attribute_Id := Get_Attribute_Id (Attribute_Name (N)); Id : constant Attribute_Id := Get_Attribute_Id (Attribute_Name (N));
begin begin
case Id is case Id is
when Attribute_Old | when Attribute_Old |
Attribute_Result => Attribute_Result =>
Expand_N_Attribute_Reference (N); Expand_N_Attribute_Reference (N);
when others => when others =>
......
...@@ -7865,20 +7865,6 @@ entity. ...@@ -7865,20 +7865,6 @@ entity.
@end cartouche @end cartouche
Followed. Followed.
@cindex pragma Volatile
@findex Volatile
@unnumberedsec C.6(16): Definition of effect of pragma Volatile
@sp 1
@cartouche
All tasks of the program (on all processors) that read or update volatile
variables see the same order of updates to the variables.
@end cartouche
The semantics for pragma volatile is that provided by the gcc back-end for
implementation of volatile in C or C++. On some targets this may meet the
serialization requirement stated above. On other targets this implementation
advice is not followed.
@cindex Package @code{Task_Attributes} @cindex Package @code{Task_Attributes}
@findex Task_Attributes @findex Task_Attributes
@unnumberedsec C.7.2(30): The Package Task_Attributes @unnumberedsec C.7.2(30): The Package Task_Attributes
......
...@@ -10312,6 +10312,7 @@ package body Sem_Ch3 is ...@@ -10312,6 +10312,7 @@ package body Sem_Ch3 is
-- type, so we must be sure not to overwrite these entries. -- type, so we must be sure not to overwrite these entries.
declare declare
Append : Boolean;
Item : Node_Id; Item : Node_Id;
Next_Item : Node_Id; Next_Item : Node_Id;
...@@ -10330,15 +10331,29 @@ package body Sem_Ch3 is ...@@ -10330,15 +10331,29 @@ package body Sem_Ch3 is
-- is not done, as that would create a circularity. -- is not done, as that would create a circularity.
elsif Item /= First_Rep_Item (Priv) then elsif Item /= First_Rep_Item (Priv) then
Append := True;
loop loop
Next_Item := Next_Rep_Item (Item); Next_Item := Next_Rep_Item (Item);
exit when No (Next_Item); exit when No (Next_Item);
Item := Next_Item; Item := Next_Item;
-- If the private view has aspect specifications, the full view
-- inherits them. Since these aspects may already have been
-- attached to the full view during derivation, do not append
-- them if already present.
if Item = First_Rep_Item (Priv) then
Append := False;
exit;
end if;
end loop; end loop;
-- And link the private type items at the end of the chain -- And link the private type items at the end of the chain
Set_Next_Rep_Item (Item, First_Rep_Item (Priv)); if Append then
Set_Next_Rep_Item (Item, First_Rep_Item (Priv));
end if;
end if; end if;
end; end;
......
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