Reputation: 1247
I am using Emacs 23 to do some C development, with GUD (using GDB) as my debugger.
I have looked online, but haven't yet found an equivalent to Visual Studio's Watch Window in GUD. Essentially, this window lets you insert a list of expressions, which are evaluated each time the program is stepped, and shows you their value. Is there a similar feature to this in GUD?
I have seen that GDB has a feature called watch points, but that is not what I'm looking for.
Upvotes: 1
Views: 306
Reputation: 30708
Probably not a complete answer to what you want, but this might help wrt the Lisp debugger: Use e
to evaluate a Lisp sexp that you enter. This can be as complex as you like. In particular, it can be a sexp that uses, say, pp-eval-expression
to show, in another window, a complex return value from evaluating a sexp. Naturally, you can have a single sexp evaluate multiple sexps.
Having done this once, just use e
with M-p
to repeat it anytime during debugging, to get the updated evaluations of the sexps. You can also select the sexp as the secondary selection, and they use M-mouse-2
to retrieve it for e
at any time.
Upvotes: 0