Bug 159270
| Summary: | Spurious "Can't create duplicate variable that shadows a global property" | ||
|---|---|---|---|
| Product: | WebKit | Reporter: | Domenic Denicola <d> |
| Component: | JavaScriptCore | Assignee: | Nobody <webkit-unassigned> |
| Status: | RESOLVED DUPLICATE | ||
| Severity: | Normal | CC: | cdumez, fpizlo, saam |
| Priority: | P2 | ||
| Version: | Safari Technology Preview | ||
| Hardware: | Mac | ||
| OS: | OS X 10.11 | ||
Domenic Denicola
https://settings-object-worker-client-ckrcsrtdqr.now.sh/ (source at https://settings-object-worker-client-ckrcsrtdqr.now.sh/_src) triggers "SyntaxError: Can't create duplicate variable that shadows a global property: 'c'"
The window has a named property 'c' since I declare an <iframe> with id="c". But then I tried to do `const c = document.querySelector("#c").contentWindow` and got that error.
That error does not appear in other browsers, and I believe has no support in the specs. (Not that window.c is supposed to be configurable.)
| Attachments | ||
|---|---|---|
| Add attachment proposed patch, testcase, etc. |
Saam Barati
Indeed. This is wrong and we already have a bug open to fix it.
Saam Barati
*** This bug has been marked as a duplicate of bug 148763 ***