Skip to content

Commit 1387501

Browse files
chore: fix remaining compiler warnings (#66)
There were two places left: another usage of the deprecated MLIR `cast` and a `default` label in a switch that already covers all cases. Signed-off-by: Ingo Müller <[email protected]>
1 parent 5e04287 commit 1387501

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

lib/Dialect/Substrait/IR/Substrait.cpp

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -189,7 +189,7 @@ EmitOp::inferReturnTypes(MLIRContext *context, std::optional<Location> loc,
189189

190190
ArrayAttr mapping = typedProperties->getMapping();
191191
Type inputType = operands[0].getType();
192-
ArrayRef<Type> inputTypes = inputType.cast<TupleType>().getTypes();
192+
ArrayRef<Type> inputTypes = mlir::cast<TupleType>(inputType).getTypes();
193193

194194
// Map input types to output types.
195195
SmallVector<Type> outputTypes;
@@ -342,8 +342,6 @@ JoinOp::inferReturnTypes(MLIRContext *context, std::optional<Location> loc,
342342
case JoinTypeKind::single:
343343
llvm::append_range(fieldTypes, rightFieldTypes);
344344
break;
345-
default:
346-
return failure();
347345
}
348346

349347
auto resultType = TupleType::get(context, fieldTypes);

0 commit comments

Comments
 (0)