[flang-commits] [flang] [flang][Semantics] Check defined-operator purity at the use site (PR #229976)

via flang-commits flang-commits at lists.llvm.org
Thu Oct 15 04:38:14 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 h,cpp -- flang/include/flang/Semantics/expression.h flang/lib/Semantics/expression.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/flang/lib/Semantics/expression.cpp b/flang/lib/Semantics/expression.cpp
index e9c177356..c150aaa05 100644
--- a/flang/lib/Semantics/expression.cpp
+++ b/flang/lib/Semantics/expression.cpp
@@ -4518,9 +4518,9 @@ MaybeExpr ExpressionAnalyzer::Analyze(const parser::Expr::Concat &x) {
 MaybeExpr ExpressionAnalyzer::AnalyzeDefinedOp(const parser::Name &name,
     ActualArguments &&actuals, const Symbol *&symbol,
     parser::CharBlock callSite) {
-  // Reference checks, such as F2023 C1595 (which requires that a procedure 
-  // referenced within a pure subprogram be pure), must be performed at the 
-  // point of use. Therefore, callSite is used instead of the current source 
+  // Reference checks, such as F2023 C1595 (which requires that a procedure
+  // referenced within a pure subprogram be pure), must be performed at the
+  // point of use. Therefore, callSite is used instead of the current source
   // location.
   if (auto callee{GetCalleeAndArguments(name, std::move(actuals))}) {
     auto &proc{std::get<evaluate::ProcedureDesignator>(callee->u)};

``````````

</details>


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


More information about the flang-commits mailing list