[llvm-branch-commits] [clang-tools-extra] [clang-doc][nfc] Use static declarations to enforce internal linkage (PR #198072)

via llvm-branch-commits llvm-branch-commits at lists.llvm.org
Fri May 15 23:58:41 PDT 2026


github-actions[bot] wrote:

<!--LLVM CODE FORMAT COMMENT: {clang-format}-->


:warning: C/C++ code formatter, clang-format found issues in your code. :warning:

<details>
<summary>
You can test this locally with the following command:
</summary>

``````````bash
git-clang-format --diff origin/main HEAD --extensions cpp -- clang-tools-extra/clang-doc/YAMLGenerator.cpp --diff_from_common_commit
``````````

:warning:
The reproduction instructions above might return results for more than one PR
in a stack if you are using a stacked PR workflow. You can limit the results by
changing `origin/main` to the base branch/commit you want to compare against.
:warning:

</details>

<details>
<summary>
View the diff from clang-format here.
</summary>

``````````diff
diff --git a/clang-tools-extra/clang-doc/YAMLGenerator.cpp b/clang-tools-extra/clang-doc/YAMLGenerator.cpp
index 83869b7a1..861a42935 100644
--- a/clang-tools-extra/clang-doc/YAMLGenerator.cpp
+++ b/clang-tools-extra/clang-doc/YAMLGenerator.cpp
@@ -35,7 +35,7 @@ namespace llvm {
 
 template <typename T>
 static bool operator==(const llvm::simple_ilist<T> &LHS,
-                const llvm::simple_ilist<T> &RHS) {
+                       const llvm::simple_ilist<T> &RHS) {
   auto LIt = LHS.begin(), LEnd = LHS.end();
   auto RIt = RHS.begin(), REnd = RHS.end();
   for (; LIt != LEnd && RIt != REnd; ++LIt, ++RIt) {
@@ -47,7 +47,7 @@ static bool operator==(const llvm::simple_ilist<T> &LHS,
 
 template <typename T>
 static bool operator!=(const llvm::simple_ilist<T> &LHS,
-                const llvm::simple_ilist<T> &RHS) {
+                       const llvm::simple_ilist<T> &RHS) {
   return !(LHS == RHS);
 }
 

``````````

</details>


https://github.com/llvm/llvm-project/pull/198072


More information about the llvm-branch-commits mailing list