[IR] Delete unused Argument::removeAttr overload

It doesn't make sense to remove an AttributeList from an argument.

llvm-svn: 301663
This commit is contained in:
Reid Kleckner 2017-04-28 17:58:18 +00:00
parent 109b236850
commit 6a752c4d30
2 changed files with 0 additions and 11 deletions

View File

@ -115,8 +115,6 @@ public:
void addAttr(Attribute Attr);
/// Remove attributes from an argument.
void removeAttr(AttributeList AS);
void removeAttr(Attribute::AttrKind Kind);
/// Check if an argument has a given attribute.

View File

@ -152,15 +152,6 @@ void Argument::addAttr(Attribute Attr) {
getParent()->addAttribute(getArgNo() + 1, Attr);
}
void Argument::removeAttr(AttributeList AS) {
assert(AS.getNumSlots() <= 1 &&
"Trying to remove more than one attribute set from an argument!");
AttrBuilder B(AS, AS.getSlotIndex(0));
getParent()->removeAttributes(
getArgNo() + 1,
AttributeList::get(Parent->getContext(), getArgNo() + 1, B));
}
void Argument::removeAttr(Attribute::AttrKind Kind) {
getParent()->removeAttribute(getArgNo() + 1, Kind);
}