diff options
author | Ed Schonberg <schonberg@adacore.com> | 2009-11-30 14:11:59 +0000 |
---|---|---|
committer | Arnaud Charlet <charlet@gcc.gnu.org> | 2009-11-30 15:11:59 +0100 |
commit | a97e4e3fb5970d33aa35c3422499dc38879905c0 (patch) | |
tree | 36aa636c0a116078853edb0326bf8f73e3075e97 /gcc | |
parent | fd22cd216b0bb01b882467b4682c7b0f6eee7026 (diff) | |
download | gcc-a97e4e3fb5970d33aa35c3422499dc38879905c0.zip gcc-a97e4e3fb5970d33aa35c3422499dc38879905c0.tar.gz gcc-a97e4e3fb5970d33aa35c3422499dc38879905c0.tar.bz2 |
gnat_rm.texi, [...]: Document new syntax for pragma Annotate
2009-11-30 Ed Schonberg <schonberg@adacore.com>
* gnat_rm.texi, gnat_ugn.texi: Document new syntax for pragma Annotate
From-SVN: r154805
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/ada/ChangeLog | 4 | ||||
-rw-r--r-- | gcc/ada/gnat_rm.texi | 15 | ||||
-rw-r--r-- | gcc/ada/gnat_ugn.texi | 6 |
3 files changed, 16 insertions, 9 deletions
diff --git a/gcc/ada/ChangeLog b/gcc/ada/ChangeLog index e5cd72b..a735c07 100644 --- a/gcc/ada/ChangeLog +++ b/gcc/ada/ChangeLog @@ -1,3 +1,7 @@ +2009-11-30 Ed Schonberg <schonberg@adacore.com> + + * gnat_rm.texi, gnat_ugn.texi: Document new syntax for pragma Annotate + 2009-11-30 Robert Dewar <dewar@adacore.com> * scans.ads (Wide_Wide_Character_Found): New flag diff --git a/gcc/ada/gnat_rm.texi b/gcc/ada/gnat_rm.texi index 7744f15..1c7f64e 100644 --- a/gcc/ada/gnat_rm.texi +++ b/gcc/ada/gnat_rm.texi @@ -929,7 +929,7 @@ same syntax and effect. @noindent Syntax: @smallexample @c ada -pragma Annotate (IDENTIFIER @{, ARG@}); +pragma Annotate (IDENTIFIER [,IDENTIFIER] @{, ARG@}); ARG ::= NAME | EXPRESSION @end smallexample @@ -937,11 +937,14 @@ ARG ::= NAME | EXPRESSION @noindent This pragma is used to annotate programs. @var{identifier} identifies the type of annotation. GNAT verifies that it is an identifier, but does -not otherwise analyze it. The @var{arg} argument -can be either a string literal or an -expression. String literals are assumed to be of type -@code{Standard.String}. Names of entities are simply analyzed as entity -names. All other expressions are analyzed as expressions, and must be +not otherwise analyze it. The second optional identifier is also left +unanalyzed, and by convention is used to control the action of the tool to +which the annotation is addressed. The remaining @var{arg} arguments +can be either string literals or more generally expressions. +String literals are assumed to be either of type +@code{Standard.String} or else @code{Wide_String} or @code{Wide_Wide_String} +depending on the character literals they contain. +All other kinds of arguments are analyzed as expressions, and must be unambiguous. The analyzed pragma is retained in the tree, but not otherwise processed diff --git a/gcc/ada/gnat_ugn.texi b/gcc/ada/gnat_ugn.texi index 87faf97..78bbf56 100644 --- a/gcc/ada/gnat_ugn.texi +++ b/gcc/ada/gnat_ugn.texi @@ -21028,7 +21028,7 @@ exemption control annotations is as follows: @group pragma Annotate (gnatcheck, @i{exemption_control}, @i{Rule_Name}, [@i{justification}]); -@i{exemption_control} ::= "Exempt_On" | "Exempt_Off" +@i{exemption_control} ::= Exempt_On | Exempt_Off @i{Rule_Name} ::= string_literal @@ -21052,9 +21052,9 @@ A source code section where an exemption is active for a given rule is delimited by an @code{exempt_on} and @code{exempt_off} annotation pair: @smallexample @c ada -pragma Annotate (gnatcheck, "Exempt_On", Rule_Name, "justification"); +pragma Annotate (gnatcheck, Exempt_On, Rule_Name, "justification"); -- source code section -pragma Annotate (gnatcheck, "Exempt_Off", Rule_Name); +pragma Annotate (gnatcheck, Exempt_Off, Rule_Name); @end smallexample |