Be more specific about return type of MachOUniversalBinary::getObjectForArch

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@220230 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Alexey Samsonov 2014-10-20 20:30:57 +00:00
parent 10051f0f62
commit 9170808b2a
2 changed files with 4 additions and 6 deletions

View File

@ -25,8 +25,6 @@
namespace llvm {
namespace object {
class ObjectFile;
class MachOUniversalBinary : public Binary {
virtual void anchor();
@ -58,7 +56,7 @@ public:
return T.getArchName();
}
ErrorOr<std::unique_ptr<ObjectFile>> getAsObjectFile() const;
ErrorOr<std::unique_ptr<MachOObjectFile>> getAsObjectFile() const;
std::error_code getAsArchive(std::unique_ptr<Archive> &Result) const;
};
@ -102,7 +100,7 @@ public:
return V->isMachOUniversalBinary();
}
ErrorOr<std::unique_ptr<ObjectFile>>
ErrorOr<std::unique_ptr<MachOObjectFile>>
getObjectForArch(Triple::ArchType Arch) const;
};

View File

@ -67,7 +67,7 @@ MachOUniversalBinary::ObjectForArch::ObjectForArch(
}
}
ErrorOr<std::unique_ptr<ObjectFile>>
ErrorOr<std::unique_ptr<MachOObjectFile>>
MachOUniversalBinary::ObjectForArch::getAsObjectFile() const {
if (Parent) {
StringRef ParentData = Parent->getData();
@ -139,7 +139,7 @@ static bool getCTMForArch(Triple::ArchType Arch, MachO::CPUType &CTM) {
}
}
ErrorOr<std::unique_ptr<ObjectFile>>
ErrorOr<std::unique_ptr<MachOObjectFile>>
MachOUniversalBinary::getObjectForArch(Triple::ArchType Arch) const {
MachO::CPUType CTM;
if (!getCTMForArch(Arch, CTM))