Skip to content

Commit 86320e0

Browse files
[mlir] Fix warnings
This patch fixes: mlir/lib/Dialect/OpenMP/IR/OpenMPDialect.cpp:3047:16: error: unused variable 'ctx' [-Werror,-Wunused-variable] mlir/lib/Dialect/OpenMP/IR/OpenMPDialect.cpp:3171:16: error: unused variable 'ctx' [-Werror,-Wunused-variable]
1 parent 9b0ae6c commit 86320e0

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

mlir/lib/Dialect/OpenMP/IR/OpenMPDialect.cpp

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3044,8 +3044,7 @@ mlir::omp ::decodeCli(Value cli) {
30443044
if (!cli)
30453045
return {{}, nullptr, nullptr};
30463046

3047-
MLIRContext *ctx = cli.getContext();
3048-
assert(cli.getType() == CanonicalLoopInfoType::get(ctx) &&
3047+
assert(cli.getType() == CanonicalLoopInfoType::get(cli.getContext()) &&
30493048
"Unexpected type of cli");
30503049

30513050
NewCliOp create = cast<NewCliOp>(cli.getDefiningOp());
@@ -3168,8 +3167,7 @@ void NewCliOp::getAsmResultNames(OpAsmSetValueNameFn setNameFn) {
31683167
LogicalResult NewCliOp::verify() {
31693168
Value cli = getResult();
31703169

3171-
MLIRContext *ctx = cli.getContext();
3172-
assert(cli.getType() == CanonicalLoopInfoType::get(ctx) &&
3170+
assert(cli.getType() == CanonicalLoopInfoType::get(cli.getContext()) &&
31733171
"Unexpected type of cli");
31743172

31753173
// Check that the CLI is used in at most generator and one consumer

0 commit comments

Comments
 (0)