summaryrefslogtreecommitdiff
path: root/lld/unittests
diff options
context:
space:
mode:
authorPete Cooper <peter_cooper@apple.com>2016-03-30 23:43:27 +0000
committerPete Cooper <peter_cooper@apple.com>2016-03-30 23:43:27 +0000
commit68ea08526ff639e0d6d0f450f7f231d3f13490fb (patch)
treec84e4b51cb18bca3f39ef4119465e63eb9f3463f /lld/unittests
parent73c5de00696e8b675f47b6262aac7e80a9b5f672 (diff)
Convert normalized file to atoms methods to new error handling. NFC.
This converts almost all of the error handling in atom creation to llvm::Error instead of std::error_code.
Diffstat (limited to 'lld/unittests')
-rw-r--r--lld/unittests/MachOTests/MachONormalizedFileToAtomsTests.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/lld/unittests/MachOTests/MachONormalizedFileToAtomsTests.cpp b/lld/unittests/MachOTests/MachONormalizedFileToAtomsTests.cpp
index af0be85b83e..91b18aabfab 100644
--- a/lld/unittests/MachOTests/MachONormalizedFileToAtomsTests.cpp
+++ b/lld/unittests/MachOTests/MachONormalizedFileToAtomsTests.cpp
@@ -19,7 +19,7 @@ using namespace llvm::MachO;
TEST(ToAtomsTest, empty_obj_x86_64) {
NormalizedFile f;
f.arch = lld::MachOLinkingContext::arch_x86_64;
- ErrorOr<std::unique_ptr<const lld::File>> atom_f =
+ llvm::Expected<std::unique_ptr<const lld::File>> atom_f =
normalizedToAtoms(f, "", false);
EXPECT_FALSE(!atom_f);
EXPECT_EQ(0U, (*atom_f)->defined().size());
@@ -59,7 +59,7 @@ TEST(ToAtomsTest, basic_obj_x86_64) {
bazSymbol.value = 3;
f.localSymbols.push_back(bazSymbol);
- ErrorOr<std::unique_ptr<const lld::File>> atom_f =
+ llvm::Expected<std::unique_ptr<const lld::File>> atom_f =
normalizedToAtoms(f, "", false);
EXPECT_FALSE(!atom_f);
const lld::File &file = **atom_f;