Bug 277899

Summary: Object.keys(global) includes non-enumerable properties unless delete'd first
Product: WebKit Reporter: Meghan Denny <meghan>
Component: JavaScriptCoreAssignee: Keith Miller <keith_miller>
Status: RESOLVED FIXED    
Severity: Normal CC: ashvayka, karlcow, keith_miller, mark.lam, webkit-bug-importer, ysuzuki
Priority: P2 Keywords: BrowserCompat, InRadar
Version: Safari 17   
Hardware: Unspecified   
OS: Unspecified   

Meghan Denny
Reported 2024-08-10 01:29:19 PDT
Discovered on Safari Version 17.5 (19618.2.12.11.6) \> Object.keys(globalThis).includes("setInterval") \< true \> const d = Object.getOwnPropertyDescriptor(globalThis, "setInterval"); \> d.enumerable = false; \> Object.defineProperty(globalThis, "setInterval", d); \> Object.getOwnPropertyDescriptor(globalThis, "setInterval").enumerable \< false \> Object.keys(globalThis).includes("setInterval") \< true the final call should return false. am unable to reproduce in Chrome Version 129.0.6647.0. am unable to reproduce in Firefox 129.0. am unable to reproduce with values that are not globalThis.
Attachments
Radar WebKit Bug Importer
Comment 1 2024-08-17 01:30:21 PDT
Keith Miller
Comment 2 2024-08-20 10:01:02 PDT
EWS
Comment 3 2024-08-21 03:36:15 PDT
Committed 282554@main (eed6352f9b23): <https://commits.webkit.org/282554@main> Reviewed commits have been landed. Closing PR #32462 and removing active labels.
Note You need to log in before you can comment on or make changes to this bug.