diff options
author | River Riddle <riverriddle@google.com> | 2020-01-11 08:54:04 -0800 |
---|---|---|
committer | River Riddle <riverriddle@google.com> | 2020-01-11 08:54:39 -0800 |
commit | 2bdf33cc4c733342fc83081bc7410ac5e9a24f55 (patch) | |
tree | 3306d769c2bbabda1060928e0cea79d021ea9da2 /mlir/test/lib/TestDialect/TestDialect.cpp | |
parent | 1d641daf260308815d014d1bf1b424a1ed1e7277 (diff) | |
download | bcm5719-llvm-2bdf33cc4c733342fc83081bc7410ac5e9a24f55.tar.gz bcm5719-llvm-2bdf33cc4c733342fc83081bc7410ac5e9a24f55.zip |
[mlir] NFC: Remove Value::operator* and Value::operator-> now that Value is properly value-typed.
Summary: These were temporary methods used to simplify the transition.
Reviewed By: antiagainst
Differential Revision: https://reviews.llvm.org/D72548
Diffstat (limited to 'mlir/test/lib/TestDialect/TestDialect.cpp')
-rw-r--r-- | mlir/test/lib/TestDialect/TestDialect.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/mlir/test/lib/TestDialect/TestDialect.cpp b/mlir/test/lib/TestDialect/TestDialect.cpp index 21cf69ec1fa..fef1f653307 100644 --- a/mlir/test/lib/TestDialect/TestDialect.cpp +++ b/mlir/test/lib/TestDialect/TestDialect.cpp @@ -100,7 +100,7 @@ struct TestInlinerInterface : public DialectInlinerInterface { // Replace the values directly with the return operands. assert(returnOp.getNumOperands() == valuesToRepl.size()); for (const auto &it : llvm::enumerate(returnOp.getOperands())) - valuesToRepl[it.index()]->replaceAllUsesWith(it.value()); + valuesToRepl[it.index()].replaceAllUsesWith(it.value()); } /// Attempt to materialize a conversion for a type mismatch between a call @@ -113,7 +113,7 @@ struct TestInlinerInterface : public DialectInlinerInterface { Location conversionLoc) const final { // Only allow conversion for i16/i32 types. if (!(resultType.isInteger(16) || resultType.isInteger(32)) || - !(input->getType().isInteger(16) || input->getType().isInteger(32))) + !(input.getType().isInteger(16) || input.getType().isInteger(32))) return nullptr; return builder.create<TestCastOp>(conversionLoc, resultType, input); } @@ -298,12 +298,12 @@ LogicalResult mlir::OpWithInferTypeInterfaceOp::inferReturnTypes( llvm::Optional<Location> location, ValueRange operands, ArrayRef<NamedAttribute> attributes, RegionRange regions, SmallVectorImpl<Type> &inferedReturnTypes) { - if (operands[0]->getType() != operands[1]->getType()) { + if (operands[0].getType() != operands[1].getType()) { return emitOptionalError(location, "operand type mismatch ", - operands[0]->getType(), " vs ", - operands[1]->getType()); + operands[0].getType(), " vs ", + operands[1].getType()); } - inferedReturnTypes.assign({operands[0]->getType()}); + inferedReturnTypes.assign({operands[0].getType()}); return success(); } |