[Lldb-commits] [PATCH] [NativeProcessLinux] Use lambdas in DoOperation calls
Tamas Berghammer
tberghammer at google.com
Thu Jun 25 03:45:30 PDT 2015
Looks good, but please check it compiles on all supported architecture (x86_64, arm, aarch64, mips/mips64) because some of the code only used on one of these.
================
Comment at: source/Plugins/Process/Linux/NativeProcessLinux.cpp:259
@@ -258,3 +258,3 @@
ProcessPOSIXLog::DecNestLevel();
- return bytes_read;
+ return error;
}
----------------
(nit): You can do a "return Error();" here
================
Comment at: source/Plugins/Process/Linux/NativeProcessLinux.cpp:713
@@ -901,3 +712,3 @@
case operation_command:
- m_operation->Execute(m_native_process);
+ m_operation_error = (*m_operation)();
break;
----------------
(nit): I think "m_operation->operator()();" is cleaner but it is up to you
================
Comment at: source/Plugins/Process/Linux/NativeProcessLinux.cpp:253
@@ -253,2 +252,3 @@
{
+ Error error;
data = NativeProcessLinux::PtraceWrapper(PTRACE_PEEKDATA, pid, (void*)vm_addr, nullptr, 0, error);
----------------
(nit) You don't need this. ("return Error();")
http://reviews.llvm.org/D10694
EMAIL PREFERENCES
http://reviews.llvm.org/settings/panel/emailpreferences/
More information about the lldb-commits
mailing list