[flang-commits] [flang] df2f346 - [flang] Silence build warning (#183393)

via flang-commits flang-commits at lists.llvm.org
Thu Feb 26 07:12:39 PST 2026


Author: Peter Klausler
Date: 2026-02-26T07:12:34-08:00
New Revision: df2f3460da63dccd96c343dad44619fce09c57a8

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

LOG: [flang] Silence build warning (#183393)

Add a [[maybe_unused]] to a parameter of a function with several
constexpr ifs, some of whose branches don't use the parameter.

Added: 
    

Modified: 
    flang/include/flang/Semantics/expression.h

Removed: 
    


################################################################################
diff  --git a/flang/include/flang/Semantics/expression.h b/flang/include/flang/Semantics/expression.h
index 4de20f5ea46a5..0a78ac019972e 100644
--- a/flang/include/flang/Semantics/expression.h
+++ b/flang/include/flang/Semantics/expression.h
@@ -580,7 +580,8 @@ class ExprChecker {
 
 private:
   template <typename A>
-  void AnalyzeAndNoteUses(const A &x, bool isDefinition = false) {
+  void AnalyzeAndNoteUses(
+      const A &x, [[maybe_unused]] bool isDefinition = false) {
     exprAnalyzer_.Analyze(x);
     if constexpr (parser::HasTypedExpr<A>::value) {
       if (x.typedExpr && x.typedExpr->v) {


        


More information about the flang-commits mailing list