diff options
author | yurys@google.com <yurys@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-05-05 17:49:20 +0000 |
---|---|---|
committer | yurys@google.com <yurys@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-05-05 17:49:20 +0000 |
commit | 0183b9b4326504a17a179b4433e9e4513401fcbc (patch) | |
tree | 8e6ef5979ed26d101c2549438243fb122a0d813d /webkit | |
parent | 4b41b801295e6f10583a77ed5fe992b02d44528a (diff) | |
download | chromium_src-0183b9b4326504a17a179b4433e9e4513401fcbc.zip chromium_src-0183b9b4326504a17a179b4433e9e4513401fcbc.tar.gz chromium_src-0183b9b4326504a17a179b4433e9e4513401fcbc.tar.bz2 |
In OOP-sytle JavaScript programs there are lots of anonymous functions which in fact are methods. Show the method names for them.
Review URL: http://codereview.chromium.org/108018
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@15306 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'webkit')
-rw-r--r-- | webkit/glue/devtools/js/debugger_agent.js | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/webkit/glue/devtools/js/debugger_agent.js b/webkit/glue/devtools/js/debugger_agent.js index 3e58e80..c403a0b 100644 --- a/webkit/glue/devtools/js/debugger_agent.js +++ b/webkit/glue/devtools/js/debugger_agent.js @@ -566,13 +566,7 @@ devtools.DebuggerAgent.formatCallFrame_ = function(stackFrame, script, msg) { */ devtools.DebuggerAgent.formatFunctionCall_ = function(stackFrame, msg) { var func = msg.lookup(stackFrame.func.ref); - if (func.name) { - return func.name; - } else { - // TODO(yurys): support method name inference(F.m = function() {} should be - // a function with name 'm') - return '(anonymous function)'; - } + return func.name || func.inferredName || '(anonymous function)'; }; |