apolyakov added inline comments.
================ Comment at: tools/lldb-mi/MICmdCmdExec.cpp:137 + auto successHandler = [this] { + // CODETAG_DEBUG_SESSION_RUNNING_PROG_RECEIVED_SIGINT_PAUSE_PROGRAM + if (!CMIDriver::Instance().SetDriverStateRunningDebugging()) { ---------------- aprantl wrote: > Is this a copy&paste error? It is, thanks. ================ Comment at: tools/lldb-mi/MICmdCmdExec.cpp:142 + MIRSRC(IDS_CMD_ERR_SET_NEW_DRIVER_STATE), + this->m_cmdData.strMiCmd.c_str(), + rErrMsg.c_str())); ---------------- aprantl wrote: > Might want to factor this out into a HandleBoolReturnValue helper if it > appears more than once. The good solution is to add anonymous namespace with a function `bool HandleDriverStateChanging(bool status, CMICmdBase *cmd)`, but it's impossible since `SetError` and `m_cmdData` are protected members of `CMICmdBase`. Another way is to add this function to CMICmdBase, but again there are only 3 commands that use that code. It seems unreasonable to do it for all commands. https://reviews.llvm.org/D47992 _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits