[mlir][LLVMIR][NFC] Remove duplicate getUnnamedAddrAttrName uses in op printers (#146090)
Fix `UnnamedAddrAttrName` being inserted twice into the `elidedAttrs` list for the attribute dictionary printer in `GlobalOp` and `AliasOp` print functions.
This commit is contained in:
@@ -2245,8 +2245,7 @@ void GlobalOp::print(OpAsmPrinter &p) {
|
||||
getGlobalTypeAttrName(), getConstantAttrName(),
|
||||
getValueAttrName(), getLinkageAttrName(),
|
||||
getUnnamedAddrAttrName(), getThreadLocal_AttrName(),
|
||||
getVisibility_AttrName(), getComdatAttrName(),
|
||||
getUnnamedAddrAttrName()});
|
||||
getVisibility_AttrName(), getComdatAttrName()});
|
||||
|
||||
// Print the trailing type unless it's a string global.
|
||||
if (llvm::dyn_cast_or_null<StringAttr>(getValueOrNull()))
|
||||
@@ -2588,7 +2587,7 @@ void AliasOp::print(OpAsmPrinter &p) {
|
||||
{SymbolTable::getSymbolAttrName(),
|
||||
getAliasTypeAttrName(), getLinkageAttrName(),
|
||||
getUnnamedAddrAttrName(), getThreadLocal_AttrName(),
|
||||
getVisibility_AttrName(), getUnnamedAddrAttrName()});
|
||||
getVisibility_AttrName()});
|
||||
|
||||
// Print the trailing type.
|
||||
p << " : " << getType() << ' ';
|
||||
|
||||
Reference in New Issue
Block a user