<html>
    <head>
      <base href="https://bugs.webkit.org/" />
    </head>
    <body>
      <p>
        <div>
            <b><a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - [JSC] fix error message for eval/arguments CoverInitializedName in strict code"
   href="https://bugs.webkit.org/show_bug.cgi?id=152304#c10">Comment # 10</a>
              on <a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - [JSC] fix error message for eval/arguments CoverInitializedName in strict code"
   href="https://bugs.webkit.org/show_bug.cgi?id=152304">bug 152304</a>
              from <span class="vcard"><a class="email" href="mailto:caitp&#64;igalia.com" title="Caitlin Potter (:caitp) &lt;caitp&#64;igalia.com&gt;"> <span class="fn">Caitlin Potter (:caitp)</span></a>
</span></b>
        <pre>Comment on <span class=""><a href="attachment.cgi?id=267380&amp;action=diff" name="attach_267380" title="Patch (smaller/broken)">attachment 267380</a> <a href="attachment.cgi?id=267380&amp;action=edit" title="Patch (smaller/broken)">[details]</a></span>
Patch (smaller/broken)

View in context: <a href="https://bugs.webkit.org/attachment.cgi?id=267380&amp;action=review">https://bugs.webkit.org/attachment.cgi?id=267380&amp;action=review</a>

self-review:

<span class="quote">&gt; Source/JavaScriptCore/parser/Parser.cpp:2892
&gt; +        if (classifier.indicatesPossiblePattern() &amp;&amp; (pattern &amp;&amp; !match(EQUAL)))</span >

This fixes the case `({ eval = 0 } = {})`, but the `for({index=0; index+=1;} index++&lt;=10; index*2;) {    arr.add(&quot;&quot;+index);};` Sputnik test fails as well,  since it's n'either a valid pattern nor a valid expression. Probably the thing to do is avoid unnecessary re-parsing in this case, and just update the expected error to be the unexpected semicolon, and avoid re-parsing as an expression.

This probably means replacing all of the `if (kind == DestructureToExpressions) return 0;` bits with a proper error message, and most likely fixing a bunch of layout tests. Doing this means the simpler fix in code should work just fine.</pre>
        </div>
      </p>
      <hr>
      <span>You are receiving this mail because:</span>
      
      <ul>
          <li>You are the assignee for the bug.</li>
      </ul>
    </body>
</html>