diff options
author | Bob Duff <duff@adacore.com> | 2021-11-05 07:54:33 -0400 |
---|---|---|
committer | Pierre-Marie de Rodat <derodat@adacore.com> | 2021-11-10 08:57:42 +0000 |
commit | 0e988162f6e9cbb9bea998b4f1febda199769692 (patch) | |
tree | 12e58aca9976de7fb726a4991b9c94c21bf273e9 /gcc/ada/errout.ads | |
parent | 76a71469f3ea7a6cb9257cec9a34a8c8687f3d15 (diff) | |
download | gcc-0e988162f6e9cbb9bea998b4f1febda199769692.zip gcc-0e988162f6e9cbb9bea998b4f1febda199769692.tar.gz gcc-0e988162f6e9cbb9bea998b4f1febda199769692.tar.bz2 |
[Ada] Warn for bidirectional characters
gcc/ada/
* scng.adb (Check_Bidi): New procedure to give warning. Note
that this is called only for non-ASCII characters, so should not
be an efficiency issue.
(Slit): Call Check_Bidi for wide characters in string_literals.
(Minus_Case): Call Check_Bidi for wide characters in comments.
(Char_Literal_Case): Call Check_Bidi for wide characters in
character_literals. Move Accumulate_Checksum down, because
otherwise, if Err is True, the Code is uninitialized.
* errout.ads: Make the obsolete nature of "Insertion character
?" more prominent; one should not have to read several
paragraphs before finding out that it's obsolete.
Diffstat (limited to 'gcc/ada/errout.ads')
-rw-r--r-- | gcc/ada/errout.ads | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/gcc/ada/errout.ads b/gcc/ada/errout.ads index 60b1b4f..d6b8910 100644 --- a/gcc/ada/errout.ads +++ b/gcc/ada/errout.ads @@ -275,7 +275,7 @@ package Errout is -- contain subprograms to be inlined in the main program. It is also -- used by the Compiler_Unit_Warning pragma for similar reasons. - -- Insertion character ? (Question: warning message) + -- Insertion character ? (Question: warning message -- OBSOLETE) -- The character ? appearing anywhere in a message makes the message -- warning instead of a normal error message, and the text of the -- message will be preceded by "warning:" in the normal case. The @@ -302,7 +302,7 @@ package Errout is -- clear that the continuation is part of a warning message, but it is -- not necessary to go through any computational effort to include it. -- - -- Note: this usage is obsolete, use ?? ?*? ?$? ?x? ?.x? ?_x? to + -- Note: this usage is obsolete; use ?? ?*? ?$? ?x? ?.x? ?_x? to -- specify the string to be added when Warn_Doc_Switch is set to True. -- If this switch is True, then for simple ? messages it has no effect. -- This simple form is to ease transition and may be removed later |