[Webkit-unassigned] [Bug 241089] New: Misleading error message

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Sun May 29 20:43:19 PDT 2022


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

            Bug ID: 241089
           Summary: Misleading error message
           Product: WebKit
           Version: Safari 15
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: Normal
          Priority: P2
         Component: JavaScriptCore
          Assignee: webkit-unassigned at lists.webkit.org
          Reporter: 845043157 at qq.com

Steps to reproduce:

Run the program:
    for(i of 123)

Actual results:
    TypeError:undefined is not a function (near ‘...i of 123’).

Expected results:
    TypeError:Spread syntax requires  ...iterable[Symbol.iterator] to be a function.(run new Object(...123);)
    or TypeError:123 is not iterable(V8,SpiderMonkey).

    The error message confuses me where is undefined and why it is wrong.I think the following error message may be better.

-- 
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/20220530/e382558d/attachment.htm>


More information about the webkit-unassigned mailing list