/// it in its containing function.
bool hasNoAliasAttr() const;
+ /// hasSRetAttr - Return true if this argument has the sret attribute on it in
+ /// its containing function.
+ bool hasStructRetAttr() const;
+
virtual void print(std::ostream &OS) const;
void print(std::ostream *OS) const {
if (OS) print(*OS);
return getParent()->paramHasAttr(getArgNo()+1, ParamAttr::NoAlias);
}
+/// hasSRetAttr - Return true if this argument has the sret attribute on
+/// it in its containing function.
+bool Argument::hasStructRetAttr() const {
+ if (!isa<PointerType>(getType())) return false;
+ return getParent()->paramHasAttr(getArgNo()+1, ParamAttr::StructRet);
+}
+