Author: Hardik Kumar
Date: 2026-08-18T19:08:59+02:00
New Revision: 3a203640f3debf139155f30ce85f04aa0f4b3716

URL: 
https://github.com/llvm/llvm-project/commit/3a203640f3debf139155f30ce85f04aa0f4b3716
DIFF: 
https://github.com/llvm/llvm-project/commit/3a203640f3debf139155f30ce85f04aa0f4b3716.diff

LOG: [docs][clang] refactor diagnostic spec instruction and grammar nit 
(#213432)

A grammar nit found in the description of the Clang Diagnostic Subsystem
is improved.

Replace the instruction mentioning the use of "slash-newline" for
writing multiple diagnostics with the appropriate "backslashes" as that's
what is actually used for separting multiple diagnostics into more than
one line.

The change makes it more obvious on how to implement multi-line
diagnostics by dropping the slightly ambigious slash-newline.

---------

Signed-off-by: Hardik Kumar <[email protected]>

Added: 
    

Modified: 
    clang/docs/InternalsManual.md

Removed: 
    


################################################################################
diff  --git a/clang/docs/InternalsManual.md b/clang/docs/InternalsManual.md
index 147728302fca4..98e5261e30215 100644
--- a/clang/docs/InternalsManual.md
+++ b/clang/docs/InternalsManual.md
@@ -45,7 +45,7 @@ when the code is incorrect or dubious. In Clang, each 
diagnostic produced has
 {ref}`SourceLocation <SourceLocation>` to "put the caret", and a severity
 (e.g., `WARNING` or `ERROR`). They can also optionally include a number of
 arguments to the diagnostic (which fill in "%0"'s in the string) as well as a
-number of source ranges that related to the diagnostic.
+number of source ranges that are related to the diagnostic.
 
 In this section, we'll be giving examples produced by the Clang command line
 driver, but diagnostics can be {ref}`rendered in many 
diff erent ways
@@ -3612,7 +3612,8 @@ int A = B; // expected-error {{use of undeclared 
identifier 'B'}}
 ```
 
 You can place as many diagnostics on one line as you wish. To make the code
-more readable, you can use slash-newline to separate out the diagnostics.
+more readable, you can use backslashes to separate out the diagnostics into
+multiple lines.
 
 Alternatively, it is possible to specify the line on which the diagnostic
 should appear by appending `@<line>` to `expected-<type>`, for example:


        
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to