Commit aa48d61c authored by sgjesse@chromium.org's avatar sgjesse@chromium.org

Improve performance of Error.stack when stack contains local functions.

BUG=http://crbug.com/53303
TEST=Use the test case attached in the bug report.

Patch by Xianzhu Wang <wangxianzhu@google.com>

Review URL: http://codereview.chromium.org/3167042


git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5410 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
parent d59bb82f
......@@ -831,11 +831,11 @@ function FormatSourcePosition(frame) {
}
var line = "";
var functionName = frame.getFunction().name;
var methodName = frame.getMethodName();
var addPrefix = true;
var isConstructor = frame.isConstructor();
var isMethodCall = !(frame.isToplevel() || isConstructor);
if (isMethodCall) {
var methodName = frame.getMethodName();
line += frame.getTypeName() + ".";
if (functionName) {
line += functionName;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment