[Mlir-commits] [mlir] [mlir] Remove unnecessary casts (NFC) (PR #146465)
llvmlistbot at llvm.org
llvmlistbot at llvm.org
Mon Jun 30 21:13:26 PDT 2025
llvmbot wrote:
<!--LLVM PR SUMMARY COMMENT-->
@llvm/pr-subscribers-mlir
Author: Kazu Hirata (kazutakahirata)
<details>
<summary>Changes</summary>
Note that encodeStringLiteralInto returns void.
---
Full diff: https://github.com/llvm/llvm-project/pull/146465.diff
1 Files Affected:
- (modified) mlir/unittests/Dialect/SPIRV/DeserializationTest.cpp (+3-3)
``````````diff
diff --git a/mlir/unittests/Dialect/SPIRV/DeserializationTest.cpp b/mlir/unittests/Dialect/SPIRV/DeserializationTest.cpp
index 13c83c00d1523..ffe815b9be5e2 100644
--- a/mlir/unittests/Dialect/SPIRV/DeserializationTest.cpp
+++ b/mlir/unittests/Dialect/SPIRV/DeserializationTest.cpp
@@ -188,11 +188,11 @@ TEST_F(DeserializationTest, OpMemberNameSuccess) {
std::swap(typeDecl, binary);
SmallVector<uint32_t, 5> operands1 = {structType, 0};
- (void)spirv::encodeStringLiteralInto(operands1, "i1");
+ spirv::encodeStringLiteralInto(operands1, "i1");
addInstruction(spirv::Opcode::OpMemberName, operands1);
SmallVector<uint32_t, 5> operands2 = {structType, 1};
- (void)spirv::encodeStringLiteralInto(operands2, "i2");
+ spirv::encodeStringLiteralInto(operands2, "i2");
addInstruction(spirv::Opcode::OpMemberName, operands2);
binary.append(typeDecl.begin(), typeDecl.end());
@@ -227,7 +227,7 @@ TEST_F(DeserializationTest, OpMemberNameExcessOperands) {
std::swap(typeDecl, binary);
SmallVector<uint32_t, 5> operands = {structType, 0};
- (void)spirv::encodeStringLiteralInto(operands, "int32");
+ spirv::encodeStringLiteralInto(operands, "int32");
operands.push_back(42);
addInstruction(spirv::Opcode::OpMemberName, operands);
``````````
</details>
https://github.com/llvm/llvm-project/pull/146465
More information about the Mlir-commits
mailing list