[Webkit-unassigned] [Bug 157852] Web Inspector: console.trace should show something useful for bound functions

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed May 18 11:54:13 PDT 2016


https://bugs.webkit.org/show_bug.cgi?id=157852

--- Comment #2 from Joseph Pecoraro <joepeck at webkit.org> ---
* TEST
<script>
function foo() {
    bar.bind(null)();
}
function bar() {
    console.trace("inner");
}
foo();
</script>

I get:

  [Log] Trace: inner
    [f] bar (bound.html:6)
    [N] bar
    [f] foo (bound.html:3)
    [S] Global Code (bound.html:8)

So, console.trace does not stop at bound functions.

It doesn't provide a location. It could provide a location. What location should it be? The location of where the function was bound (.bind() invocation), or the location of the target function (that is already available as the next call frame).

Honestly I would have expected this:

  [Log] Trace: inner
    [f] bar (bound.html:6)
    [N] bound bar
    [f] foo (bound.html:3)
    [S] Global Code (bound.html:8)

We can probably trivially get the improved "bound bar" name when creating the trace frames.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.webkit.org/pipermail/webkit-unassigned/attachments/20160518/36922bfd/attachment-0001.html>


More information about the webkit-unassigned mailing list