[cells-devel] Re: [cells-gtk-devel] lots of circular cells in cells-gtk3?
Peter Hildebrandt
peter.hildebrandt at gmail.com
Mon Apr 14 17:08:58 UTC 2008
On Mon, Apr 14, 2008 at 6:57 PM, Ken Tilton <kennytilton at optonline.net> wrote:
> Recently some evil programming took forever to debug because I was
> re-entering a rule without realizing it. After figuring out that that was
> happening and fixing the cause of that, I looked to see why rule re-entrance
> had not been detected, which I seemed to recall it always had been.
>
> Turns out the rule began with without-c-dependency as a trick to run only
> once. That macro simply:
>
> `(let ((cells::*call-stack* nil))
> , at body)
>
> And that worked because the dependent cell was always identifed as (car
> cells::*call-stack*).
Wow, congrats for figuring that out. Sounds like one of these things
that take forever ...
> Well, I like early bug detection you may have noticed recently <g>, so I
> decided the macro without-c-dependency should leave the *call-stack* intact
> and instead bind a separate new *depender* special to nil, with *depender*
> being the, well, depender honored by the Cells machinery.
Sounds good. And you obviously found some "unclean" stuff I was doing.
> You should not have been doing cells-y stuff in i-i, but you got away with
> it because of the old without-c-dependency behavior, so...
Actually, the drawing area widget still gets away with it. Maybe
because it does not have kids ... I don't know.
> ...congratulations, you are the first victim to fall into my new bug trap.
> :)
I'm proud :)
Peter
More information about the cells-devel
mailing list