[Webkit-unassigned] [Bug 210253] New: Web Inspector: Debugger: debug hooks should also be emitted for the first sub-expression in a comma expression

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu Apr 9 00:51:30 PDT 2020


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

            Bug ID: 210253
           Summary: Web Inspector: Debugger: debug hooks should also be
                    emitted for the first sub-expression in a comma
                    expression
           Product: WebKit
           Version: WebKit Local Build
          Hardware: All
                OS: All
            Status: NEW
          Severity: Normal
          Priority: P2
         Component: Web Inspector
          Assignee: webkit-unassigned at lists.webkit.org
          Reporter: drousso at apple.com
                CC: inspector-bugzilla-changes at group.apple.com
        Depends on: 209998

After r259781, debug hooks are now generated for all but the first sub-expression in a comma expression.

[Source/JavaScriptCore/bytecompiler/NodesCodegen.cpp](http://trac.webkit.org/changeset/259781/webkit/trunk/Source/JavaScriptCore/bytecompiler/NodesCodegen.cpp):
```
    RegisterID* CommaNode::emitBytecode(BytecodeGenerator& generator, RegisterID* dst)
    {
        for (; node->next(); node = node->next()) {
            generator.emitNode(generator.ignoredResult(), node->m_expr);

            // Don't emit a debug hook for the first expression, as that should've already happened in
            // the containing statement.
            generator.emitDebugHook(node->next()->m_expr);
        }
        return generator.emitNodeInTailPosition(dst, node->m_expr);
    }
```

This comment is inaccurate, as in the simple case of `true && (a(), b())`.


Referenced Bugs:

https://bugs.webkit.org/show_bug.cgi?id=209998
[Bug 209998] Web Inspector: Debugger: treat comma sub-expressions as separate statements
-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20200409/ad954a27/attachment.htm>


More information about the webkit-unassigned mailing list