[flang-commits] [flang] [flang][OpenMP] Add diagnostic for ATOMIC WRITE with pointer to non-intrinsic type (PR #162364)
via flang-commits
flang-commits at lists.llvm.org
Tue Oct 7 13:18:42 PDT 2025
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 -- flang/lib/Semantics/check-omp-atomic.cpp
``````````
: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/flang/lib/Semantics/check-omp-atomic.cpp b/flang/lib/Semantics/check-omp-atomic.cpp
index 00c6a2d2b..5f18f7a4f 100644
--- a/flang/lib/Semantics/check-omp-atomic.cpp
+++ b/flang/lib/Semantics/check-omp-atomic.cpp
@@ -842,7 +842,8 @@ void OmpStructureChecker::CheckAtomicWriteAssignment(
if (cat != Category::Numeric && cat != Category::Logical) {
std::string details = " has the POINTER attribute";
if (const auto *derived{typeSpec->AsDerived()}) {
- details += " and derived type '"s + derived->name().ToString() + "'";
+ details +=
+ " and derived type '"s + derived->name().ToString() + "'";
}
context_.Say(lsrc,
"ATOMIC WRITE requires an intrinsic scalar variable; '%s'%s"_err_en_US,
``````````
</details>
https://github.com/llvm/llvm-project/pull/162364
More information about the flang-commits
mailing list