<html>
<head>
<base href="https://bugs.webkit.org/" />
</head>
<body>
<p>
<div>
<b><a class="bz_bug_link
bz_status_NEW "
title="NEW - [JSC] support CoverInitializedName in nested AssignmentPatterns"
href="https://bugs.webkit.org/show_bug.cgi?id=151595#c2">Comment # 2</a>
on <a class="bz_bug_link
bz_status_NEW "
title="NEW - [JSC] support CoverInitializedName in nested AssignmentPatterns"
href="https://bugs.webkit.org/show_bug.cgi?id=151595">bug 151595</a>
from <span class="vcard"><a class="email" href="mailto:caitp@igalia.com" title="Caitlin Potter (:caitp) <caitp@igalia.com>"> <span class="fn">Caitlin Potter (:caitp)</span></a>
</span></b>
<pre>Comment on <span class=""><a href="attachment.cgi?id=266144&action=diff" name="attach_266144" title="[JSC] support CoverInitializedName in nested AssignmentPatterns">attachment 266144</a> <a href="attachment.cgi?id=266144&action=edit" title="[JSC] support CoverInitializedName in nested AssignmentPatterns">[details]</a></span>
[JSC] support CoverInitializedName in nested AssignmentPatterns
View in context: <a href="https://bugs.webkit.org/attachment.cgi?id=266144&action=review">https://bugs.webkit.org/attachment.cgi?id=266144&action=review</a>
<span class="quote">> Source/JavaScriptCore/tests/es6/destructuring_assignment_nested_cover_initialized_name.js:3
> + ({ a: { b: { c = "it worked" } } } = { a: { b: {} } });</span >
To explain the regression, we now parse as an expression first, and fallback on the assignment pattern parsing if it's an object literal followed by an `=`. In this case, when initially parsing the outer ObjectLiteral as an Expression, the error occurs on the inner ObjectLiteral, and it's not followed by an `=`, so an error is reported, but the error class does not indicate that the error allows reparsing as a Pattern.
the change communicates the error class to the outer classifier, so that nested pattern errors can be handled properly by parseAssignmentExpression</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>