Bug 153310 - [ES6] Several lexical binding causes SyntaxError if there is duplicate lexical/variable decl under targetting block
Summary: [ES6] Several lexical binding causes SyntaxError if there is duplicate lexica...
Status: NEW
Alias: None
Product: WebKit
Classification: Unclassified
Component: JavaScriptCore (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Yusuke Suzuki
URL:
Keywords:
Depends on: 152385
Blocks:
  Show dependency treegraph
 
Reported: 2016-01-21 10:39 PST by Yusuke Suzuki
Modified: 2016-01-21 10:40 PST (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Yusuke Suzuki 2016-01-21 10:39:37 PST
http://ecma-international.org/ecma-262/6.0/#sec-for-statement-static-semantics-early-errors

for (let v = 42;;) {
    var v = 44;
}

should throw SyntaxError

http://ecma-international.org/ecma-262/6.0/#sec-try-statement-static-semantics-early-errors

try {
} catch (error) {
     let error = 42;
}

should throw SyntaxError


try {
} catch (error) {
     var error = 42;
}

should throw SyntaxError