[Webkit-unassigned] [Bug 93519] Web Inspector: implement WorkerScriptDebugServer
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Thu Sep 27 04:29:19 PDT 2012
https://bugs.webkit.org/show_bug.cgi?id=93519
--- Comment #5 from Peter Wang <peter.wang at torchmobile.com.cn> 2012-09-27 04:29:45 PST ---
(In reply to comment #4)
> (From update of attachment 161450 [details])
> View in context: https://bugs.webkit.org/attachment.cgi?id=161450&action=review
>
> > Source/JavaScriptCore/parser/Parser.h:1039
> > + if (debugger && !debugger->isWorkerDebugger() && !ParsedNode::scopeIsFunction)
>
> How does inspector get notified about parsed scripts in case of worker if is is skipped here?
The "JSC::WorkerScriptDebugServer::addListener" invokes "recompileAllJSFunctions" which will make "JSC::Debugger::sourceParsed" to be called.
Actually, if we don't skip here, worker inspector will have a problem in some case(refer to the attachement).
> > Source/WebCore/bindings/js/ScriptDebugServer.cpp:447
> > +void ScriptDebugServer::blockToWaitInstruction(bool& stop)
>
> I'd call it runEventLoopWhilePaused
ok.
> > Source/WebCore/bindings/js/ScriptDebugServer.h:117
> > + virtual void blockToWaitInstruction(bool& stop);
>
> m_doneProcessingDebuggerEvents is a protected field, no need to pass a reference to it as an argument.
ok, thx.
> > Source/WebCore/bindings/js/WorkerScriptDebugServer.cpp:71
> > + m_workerContext->script()->attachDebugger(this);
>
> This should happen only when first listener is added. We should probably simplify the API as I am not aware of any cases when we may have more than one listener.
yes, but JSC really needs interface "addListener" to inform of recompilation.
> > Source/WebCore/bindings/js/WorkerScriptDebugServer.cpp:81
> > + m_workerContext->script()->detachDebugger(this);
>
> This should only occur when there are no listeners.
ok
> > Source/WebCore/bindings/js/WorkerScriptDebugServer.h:48
> > + bool isWorkerDebugger() { return true; }
>
> This method should be marked virtual.
ok.
--
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
More information about the webkit-unassigned
mailing list