Skip to content

Commit

Permalink
Apply clang-tidy fixes for llvm-else-after-return in OpPythonBindingG…
Browse files Browse the repository at this point in the history
…en.cpp (NFC)
  • Loading branch information
joker-eph committed May 30, 2022
1 parent 0f68c95 commit eacfd04
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion mlir/tools/mlir-tblgen/OpPythonBindingGen.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -894,7 +894,7 @@ static void emitDefaultOpBuilder(const Operator &op, raw_ostream &os) {
Argument a = op.getArg(builderArgIndex - numResultArgs);
if (auto *nattr = a.dyn_cast<NamedAttribute *>())
return (nattr->attr.isOptional() || nattr->attr.hasDefaultValue());
else if (auto *ntype = a.dyn_cast<NamedTypeConstraint *>())
if (auto *ntype = a.dyn_cast<NamedTypeConstraint *>())
return ntype->isOptional();
else
return false;
Expand Down

0 comments on commit eacfd04

Please sign in to comment.