[Mlir-commits] [mlir] [mlir][NFC] Remove conditionally unused type alias (PR #189894)

Lukas Sommer llvmlistbot at llvm.org
Wed Apr 1 00:14:12 PDT 2026


https://github.com/sommerlukas created https://github.com/llvm/llvm-project/pull/189894

The `RawType` type alias is unused (`-Wunused-local-typedef`) in build with asserts deactivated. In combination with `-Werror`, this causes builds to fail. 

>From f73a5feccb2af566166e75d495fbfc6c842aa476 Mon Sep 17 00:00:00 2001
From: Lukas Sommer <lukas.sommer at amd.com>
Date: Wed, 1 Apr 2026 07:11:51 +0000
Subject: [PATCH] [mlir][NFC] Remove conditionally unused type alias

Signed-off-by: Lukas Sommer <lukas.sommer at amd.com>
---
 mlir/include/mlir/IR/OperationSupport.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/mlir/include/mlir/IR/OperationSupport.h b/mlir/include/mlir/IR/OperationSupport.h
index f801947f2a252..c4ba2f324df72 100644
--- a/mlir/include/mlir/IR/OperationSupport.h
+++ b/mlir/include/mlir/IR/OperationSupport.h
@@ -80,8 +80,8 @@ class PropertyRef {
   Dest as() const {
     static_assert(std::is_pointer_v<Dest>,
                   "PropertyRef::as<T>() requires T to be a pointer type");
-    using RawType = std::remove_cv_t<std::remove_pointer_t<Dest>>;
-    assert((typeID == TypeID::get<RawType>()) &&
+    assert((typeID ==
+            TypeID::get<std::remove_cv_t<std::remove_pointer_t<Dest>>>()) &&
            "Property type mismatch: TypeID does not match requested type");
     return static_cast<Dest>(data);
   }



More information about the Mlir-commits mailing list