[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Watchpoints for emacs lisp.
From: |
A. Soare |
Subject: |
Re: Watchpoints for emacs lisp. |
Date: |
Tue, 11 May 2010 15:54:12 +0200 (CEST) |
> > I insert to the struct Lisp_Symbol a field :watched: .
>
> So, no support for watching for an element of an array or pair to be changed,
> or part of a string?
Hm... I thought only to symbols, true. Not to arrays, not to numbers.
Can you use the change of an array if a symbol does not point to it? Probably
yes. There exist lambda function (functions without name), but probably one can
debug also the change of an array without name.
.....
> > Afterwards, in ALL functions that are able to change the value of a symbol,
> > I insert a checkpoint, which looks like that:
> >
> > <if the symbol to change has the flag :watched: true, that call the
> > corresponding procedure of the debugger>
> >
> > Is it ok the algorithm ? In how many obarrays should I look for the given
> > symbol ?
>
> If you do it this way, I think having a Lisp function take a symbol in which
> to set the flag, and having a user-callable function which uses (interactive
> "S") (which asks the user for a symbol name in the main obarray), is probably
> a good start. Anything that isn't in the main obarray can be provided
> directly in lisp by the developer.
>
> What about changes to the property list, or function value, of a symbol?
>
Can you figure an algorithm for checking very fast (O (0)) whether a symbol has
a given property ?
Yes, surely yes, if property lists would have been implemented with fast search
algo, which is not the case of emacs.
Alin
____________________________________________________
Les scandales de cannes, les palmes d'or, l'actualité du festival sur voila.fr
http://evenementiel.voila.fr/festival-de-cannes2010/
- Re: Watchpoints for emacs lisp., (continued)
- Re: Watchpoints for emacs lisp., alin.s, 2010/05/26
- Re: Watchpoints for emacs lisp., Stefan Monnier, 2010/05/26
- Re: Watchpoints for emacs lisp., alin.s, 2010/05/26
- Re: Watchpoints for emacs lisp., alin.s, 2010/05/27
- Re: Watchpoints for emacs lisp., Andreas Schwab, 2010/05/27
- Re: Watchpoints for emacs lisp., alin.s, 2010/05/28
- Re: Watchpoints for emacs lisp., tomas, 2010/05/29
- Re: Watchpoints for emacs lisp., Ken Raeburn, 2010/05/19
- Re: Watchpoints for emacs lisp., Adrian Robert, 2010/05/19
- Re: Watchpoints for emacs lisp., Andreas Schwab, 2010/05/17
Re: Watchpoints for emacs lisp.,
A. Soare <=