diff --git a/lib/Dialect/Moore/MooreOps.cpp b/lib/Dialect/Moore/MooreOps.cpp index ec1e1e2d8af0..8ae89bb5f893 100644 --- a/lib/Dialect/Moore/MooreOps.cpp +++ b/lib/Dialect/Moore/MooreOps.cpp @@ -48,9 +48,8 @@ void SVModuleOp::print(OpAsmPrinter &p) { p.printRegion(getBodyRegion(), /*printEntryBlockArgs=*/false, /*printBlockTerminators=*/true); - SmallVector omittedAttrs = {"sym_name", "module_type", - visibilityAttrName}; - p.printOptionalAttrDictWithKeyword((*this)->getAttrs(), omittedAttrs); + p.printOptionalAttrDictWithKeyword(getOperation()->getAttrs(), + getAttributeNames()); } ParseResult SVModuleOp::parse(OpAsmParser &parser, OperationState &result) {