Bug 144284

Summary: Extending undefined in class syntax should throw a TypeError
Product: WebKit Reporter: Erik Arvidsson <arv>
Component: JavaScriptCoreAssignee: Ryosuke Niwa <rniwa>
Status: RESOLVED FIXED    
Severity: Normal CC: barraclough, benjamin, darin, fpizlo, ggaren
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on:    
Bug Blocks: 140491    
Attachments:
Description Flags
Fixes the bug none

Description Erik Arvidsson 2015-04-27 15:38:29 PDT
http://trac.webkit.org/browser/trunk/LayoutTests/js/script-tests/class-syntax-extends.js#L73

shouldThrow('new (class extends undefined { constructor () { this } })', '"ReferenceError: Cannot access uninitialized variable."');

the `extends undefined` should throw a TypeError.
Comment 1 Ryosuke Niwa 2015-05-03 17:04:49 PDT
Created attachment 252294 [details]
Fixes the bug
Comment 2 Ryosuke Niwa 2015-05-04 12:24:15 PDT
Thanks for the reviews, Darin!
Comment 3 Ryosuke Niwa 2015-05-04 12:24:40 PDT
Comment on attachment 252294 [details]
Fixes the bug

Clearing flags on attachment: 252294

Committed r183759: <http://trac.webkit.org/changeset/183759>
Comment 4 Ryosuke Niwa 2015-05-04 12:24:46 PDT
All reviewed patches have been landed.  Closing bug.