[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Watchpoints for emacs lisp.

From: Stefan Monnier
Subject: Re: Watchpoints for emacs lisp.
Date: Sat, 15 May 2010 13:48:52 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux)

> In GDB there are watchpoints to stop when changing the value, but there are
> also watchpoints to stop when read/write.

> It should be done here the same.

I don't know about "should".  There are different kinds of watchpoint
you might be interested in, and there are different techniques you can
use to implement a watchpoint feature.  Depending on the technique you
use, that restricts the kind of watchpoints you can support.

Using a field on the `symbol' structure only allows you to catch
modifications via setq/let (and friends).  It's very limited, but has
the advantage of being very simple, cheap, and lightweight to implement.

If you want to be able to watch a random expression (which would be
great, of course), then indeed you'll need something a lot more
intrusive, such as a playing MMU tricks or adding extra checks at
various places.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]