Bug 145489

Summary: [ES6] Drop WeakMap#clear
Product: WebKit Reporter: Yusuke Suzuki <ysuzuki>
Component: JavaScriptCoreAssignee: Yusuke Suzuki <ysuzuki>
Status: RESOLVED FIXED    
Severity: Normal CC: commit-queue, darin, fpizlo, ggaren, mark.lam, oliver
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch none

Description Yusuke Suzuki 2015-05-29 23:08:55 PDT
ES6 spec intentionally drops the WeakMap#clear to allow engine to implement WeakMap as a per-object table.
Comment 1 Yusuke Suzuki 2015-05-31 03:22:54 PDT
Created attachment 253973 [details]
Patch
Comment 2 Mark Lam 2015-05-31 06:43:22 PDT
For reference:

https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/WeakMap/clear indicates that clear() "part of the ECMAScript 6 draft specification until revision 28 (version of October 14, 2014), but has been removed in later versions of the draft. It will not be part of the final standard.”

Firefox 38.0.1 still supports it.
Chrome 43.0.2357.81 has removed it.
Comment 3 Yusuke Suzuki 2015-05-31 07:21:35 PDT
Comment on attachment 253973 [details]
Patch

Thank you for your review and reference.
Comment 4 WebKit Commit Bot 2015-05-31 08:10:31 PDT
Comment on attachment 253973 [details]
Patch

Clearing flags on attachment: 253973

Committed r185041: <http://trac.webkit.org/changeset/185041>
Comment 5 WebKit Commit Bot 2015-05-31 08:10:35 PDT
All reviewed patches have been landed.  Closing bug.