[Lldb-commits] [PATCH] D67776: Use UnixSignals::ShouldSuppress to filter out signals a process expects

Tatyana Krasnukha via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Fri Sep 20 10:41:20 PDT 2019


tatyana-krasnukha added inline comments.


================
Comment at: source/Interpreter/CommandInterpreter.cpp:2164
+    StopReason reason = stop_info->GetStopReason();
+    if (eStopReasonException == reason || eStopReasonInstrumentation == reason)
+      return true;
----------------
JDevlieghere wrote:
> I'm curious why you swapped the two operands. Is there a benefit in `eStopReasonException == reason` compared to `reason == eStopReasonException`? 
This technique prevents unintended assignment instead of comparison since left-hand value is constant. 


Repository:
  rLLDB LLDB

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D67776/new/

https://reviews.llvm.org/D67776





More information about the lldb-commits mailing list