31i73 / atom-dbg

An Atom package - An interactive debugger frontend
https://atom.io/packages/dbg
MIT License
30 stars 4 forks source link

Add support for conditional break #42

Closed julian-poidevin closed 10 months ago

julian-poidevin commented 5 years ago

Adding support for expression cond break exp would be great. It will allow to let program break at the breaklocation only if expevaluates true :

  (gdb) break gdbprog.cc:35
  Breakpoint 4 at 0x23c0: file gdbprog.cc, line
  35.
  (gdb) cond 4 (i == 6)
  (gdb) run
  Starting program: gdbprog 
  operation result is 45
  0
  1
  2
  3
  4
  5

  Breakpoint 4, PrintArray () at gdbprog.cc:36
  36                      if (iArray[i] == 6)
  (gdb) step
  37                              cout << "This is an error\n";
  (gdb) next
  This is an error
  40              }