diff options
author | charlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4> | 2012-05-15 09:31:25 +0000 |
---|---|---|
committer | charlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4> | 2012-05-15 09:31:25 +0000 |
commit | a16536f8a0e3d05171d6e451987fd20ff0fa35d5 (patch) | |
tree | 0a9799184a7e726cb57be0ced06a0257a380fc77 /gcc/ada/sem_ch9.adb | |
parent | 7413d80df0db9a5082f700e04318b9d639f10b5c (diff) | |
download | gcc-a16536f8a0e3d05171d6e451987fd20ff0fa35d5.tar.gz |
2012-05-15 Robert Dewar <dewar@adacore.com>
* exp_ch9.adb, sem_ch9.adb, sem_ch13.adb: Minor reformatting.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@187506 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/ada/sem_ch9.adb')
-rw-r--r-- | gcc/ada/sem_ch9.adb | 22 |
1 files changed, 10 insertions, 12 deletions
diff --git a/gcc/ada/sem_ch9.adb b/gcc/ada/sem_ch9.adb index a91f494152f..7ce20b5f85c 100644 --- a/gcc/ada/sem_ch9.adb +++ b/gcc/ada/sem_ch9.adb @@ -70,9 +70,8 @@ package body Sem_Ch9 is function Allows_Lock_Free_Implementation (N : Node_Id; Complain : Boolean := False) return Boolean; - -- This dispatch routine return True if N satisfies the following list of - -- lock-free restrictions for protected type declaration and protected - -- body: + -- This routine returns True iff N satisfies the following list of lock- + -- free restrictions for protected type declaration and protected body: -- -- 1) Protected type declaration -- May not contain entries @@ -87,8 +86,7 @@ package body Sem_Ch9 is -- May not contain loop statements or procedure calls -- Function calls and attribute references must be static -- - -- If Complain is set to True, an error message is issued when return - -- False. + -- If Complain is True, an error message is issued when False is returned procedure Check_Max_Entries (D : Node_Id; R : All_Parameter_Restrictions); -- Given either a protected definition or a task definition in D, check @@ -134,9 +132,7 @@ package body Sem_Ch9 is -- flag. When Complain is True, an aspect Lock_Free forces the lock-free -- implementation. In that case, the debug flag is not needed. - if not Complain - and then not Debug_Flag_9 - then + if not Complain and then not Debug_Flag_9 then return False; end if; @@ -235,7 +231,7 @@ package body Sem_Ch9 is -- Protected body case else - declare + Protected_Body_Case : declare Decls : constant List_Id := Declarations (N); Pid : constant Entity_Id := Corresponding_Spec (N); Prot_Typ_Decl : constant Node_Id := Parent (Pid); @@ -392,6 +388,8 @@ package body Sem_Ch9 is end if; end Satisfies_Lock_Free_Requirements; + -- Start of processing for Protected_Body_Case + begin Decl := First (Decls); @@ -409,7 +407,7 @@ package body Sem_Ch9 is Next (Decl); end loop; - end; + end Protected_Body_Case; end if; return True; @@ -1709,8 +1707,8 @@ package body Sem_Ch9 is End_Scope; -- When a Lock_Free aspect forces the lock-free implementation, check N - -- meets all the lock-free restrictions. Otherwise, - -- Allows_Lock_Free_Implementation issue an error message. + -- meets all the lock-free restrictions. Otherwise, an error message is + -- issued by Allows_Lock_Free_Implementation. if Uses_Lock_Free (Defining_Identifier (N)) then if not Allows_Lock_Free_Implementation (N, Complain => True) then |