diff options
author | Mehdi Amini <mehdi.amini@apple.com> | 2016-11-11 04:29:25 +0000 |
---|---|---|
committer | Mehdi Amini <mehdi.amini@apple.com> | 2016-11-11 04:29:25 +0000 |
commit | c1edf566b9ba18806c9a69e77db1cc8e57a14c8d (patch) | |
tree | ea1b174a6e594d2b6929f9e4845cc2ba3d9d6f93 /lldb/unittests/Utility/ModuleCacheTest.cpp | |
parent | 41af43092ccc8030bb49cea324d85eecd5ae68a8 (diff) | |
download | bcm5719-llvm-c1edf566b9ba18806c9a69e77db1cc8e57a14c8d.tar.gz bcm5719-llvm-c1edf566b9ba18806c9a69e77db1cc8e57a14c8d.zip |
Prevent at compile time converting from Error::success() to Expected<T>
This would trigger an assertion at runtime otherwise.
Differential Revision: https://reviews.llvm.org/D26482
llvm-svn: 286562
Diffstat (limited to 'lldb/unittests/Utility/ModuleCacheTest.cpp')
-rw-r--r-- | lldb/unittests/Utility/ModuleCacheTest.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lldb/unittests/Utility/ModuleCacheTest.cpp b/lldb/unittests/Utility/ModuleCacheTest.cpp index eea26d1470d..911c278c162 100644 --- a/lldb/unittests/Utility/ModuleCacheTest.cpp +++ b/lldb/unittests/Utility/ModuleCacheTest.cpp @@ -114,7 +114,7 @@ void ModuleCacheTest::TryGetAndPut(const FileSpec &cache_dir, std::error_code ec = llvm::sys::fs::copy_file( s_test_executable, tmp_download_file_spec.GetCString()); EXPECT_FALSE(ec); - return Error::success(); + return Error(); }, [](const ModuleSP &module_sp, const FileSpec &tmp_download_file_spec) { return Error("Not supported."); |