A new :stepover command for the debugger
authorPepe Iborra <mnislaih@gmail.com>
Thu, 9 Aug 2007 20:11:49 +0000 (20:11 +0000)
committerPepe Iborra <mnislaih@gmail.com>
Thu, 9 Aug 2007 20:11:49 +0000 (20:11 +0000)
commitfcd7ba21a64c12b6e0f1053892d2698ae7d29f81
tree5a3f402d47aaa5a6dfdf79e90c67165975224017
parent7bf92baeaa558bab450bcda6e65649be082fd1a7
A new :stepover command for the debugger

  Step from statement to statement without leaving the block.
  Tries to do the sensible thing when used on expressions.

      The idea is to:
      1 - Step to the next breakpoint and examine the srcloc
      2 - If it is contained in the same statement block as we were,
          then stop and give control to the user,
        else continue to the next breakpoint
      3 - Repeat from 1. If we reach the end of the statement block,
          i.e. no more ticks in this expression after the current one,
          then step normally.

  Replace statement block with 'declaration block' (of an expression) in the
  pseudo algo. above.
  Let's see how well this idea works in practice...
compiler/ghci/InteractiveUI.hs
compiler/main/GHC.hs
compiler/main/InteractiveEval.hs