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/source/Host/common/SoftwareBreakpoint.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/source/Host/common/SoftwareBreakpoint.cpp')
-rw-r--r-- | lldb/source/Host/common/SoftwareBreakpoint.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lldb/source/Host/common/SoftwareBreakpoint.cpp b/lldb/source/Host/common/SoftwareBreakpoint.cpp index 6cb8126fb14..3d57b7dd6b8 100644 --- a/lldb/source/Host/common/SoftwareBreakpoint.cpp +++ b/lldb/source/Host/common/SoftwareBreakpoint.cpp @@ -103,7 +103,7 @@ Error SoftwareBreakpoint::CreateSoftwareBreakpoint( // breakpoint. breakpoint_sp.reset(new SoftwareBreakpoint(process, addr, saved_opcode_bytes, bp_opcode_bytes, bp_opcode_size)); - return Error::success(); + return Error(); } Error SoftwareBreakpoint::EnableSoftwareBreakpoint( @@ -219,7 +219,7 @@ Error SoftwareBreakpoint::EnableSoftwareBreakpoint( log->Printf("SoftwareBreakpoint::%s addr = 0x%" PRIx64 " -- SUCCESS", __FUNCTION__, addr); - return Error::success(); + return Error(); } // ------------------------------------------------------------------- |