Status: New
Owner: ----
New issue 2847 by [email protected]: Cannot set breakpoint at function
if function is in local scope
http://code.google.com/p/v8/issues/detail?id=2847
Here is sample script:
function testEqual(a, b) {
return a == b;
};
var func1 = function () {
console.log('func1');
};
testEqual(1, 2);
func1();
I construct 'setbreakpoint' request and send this request to v8.
{"command":"setbreakpoint","arguments":{"type":"function","target":"testEqual"},"type":"request","seq":1}
However, here is the error received from v8.
Error: "ReferenceError: testEqual is not defined" evaluating "testEqual"
I tested with node debugger and node got the same error.
I scanned debug-debugger.js code and found that if setbreakpoint
arguments.type is 'function', v8 looks up the function name on global scope
only. It doesn't evaluate function name at different scope/frame, like
evaluate request does. Is there any concern that setbreakpoint request
evaluates function through all scopes? Or Is there other workaround to set
breakpoint at function name defined at local scope?
Thanks.
Tina
--
You received this message because this project is configured to send all
issue notifications to this address.
You may adjust your notification preferences at:
https://code.google.com/hosting/settings
--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
---
You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.