Re: Implement jsdICompilationUnit
Gijs Kruitbosch <[email protected]> Wed, 02 Dec 2009 10:46:04 +0100
| Newsgroups | gmane.comp.mozilla.devel.jsdebugger |
|---|---|
| Message-ID | <[email protected]> |
On 02/12/2009 03:34 AM, Boris Zbarsky wrote: > On 12/1/09 6:29 PM, John J Barton wrote: >> The implementation is "lightly salted": a few lines need to be added in >> a lot of places. Every place JS can be compiled needs a call to the hook >> and the hook-setting code needs to propagate up through the jsd layer >> cake to the JS interface. Algorithmically the jsengine builds a simple >> list of jsdIScripts threaded through JSDScript with the head in >> JSDContext. If the compilation hook is taken, the list can be copied out >> via enumerateCompiledScripts(), else it is not useful. > > Hmm... So does this involve firebug js running when the compile happens? > I believe right now there are various places (event handlers, xbl, etc) > that assume that js compilation will not trigger random script, and in > particular won't spin the event loop. > > -Boris I think at least Venkman works around these kinds of issues by making JSD enter a nested event loop. I have no idea if Firebug does the same. http://mxr.mozilla.org/mozilla-central/source/js/jsd/idl/jsdIDebuggerService.idl#373 ~ Gijs