Commit 6603d32
src: fix vm bug for configurable globalThis
Object.defineProperty allows to change the value for
non-writable properties if they are configurable. We
missed that case when checking if a
property is read-only.
Fixes: #47799
PR-URL: #51602
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>1 parent c820166 commit 6603d32Copy full SHA for 6603d32
File tree
Expand file treeCollapse file tree
2 files changed
+21
-3
lines changedOpen diff view settings
Filter options
- src
- test/parallel
Expand file treeCollapse file tree
2 files changed
+21
-3
lines changedOpen diff view settings
Collapse file
+6-3Lines changed: 6 additions & 3 deletions
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| ||
609 | 609 | |
610 | 610 | |
611 | 611 | |
| 612 | + |
| 613 | + |
612 | 614 | |
613 | | - |
614 | | - |
615 | | - |
| 615 | + |
| 616 | + |
| 617 | + |
616 | 618 | |
| 619 | + |
617 | 620 | |
618 | 621 | |
619 | 622 | |
|
Collapse file
test/parallel/test-vm-global-configurable-properties.js
Copy file name to clipboard+15Lines changed: 15 additions & 0 deletions
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| ||
| 1 | + |
| 2 | + |
| 3 | + |
| 4 | + |
| 5 | + |
| 6 | + |
| 7 | + |
| 8 | + |
| 9 | + |
| 10 | + |
| 11 | + |
| 12 | + |
| 13 | + |
| 14 | + |
| 15 | + |
0 commit comments