LibJS: Fix bytecode generation for super property stores and loads

The new test case crashes during bytecode generation due to
`emit_super_reference` not correctly generating the reference record
for the property access.
This commit is contained in:
Jess 2025-02-13 22:10:58 +13:00 committed by Tim Flynn
parent 778947213b
commit 356728b1e0
Notes: github-actions[bot] 2025-02-15 12:01:01 +00:00
2 changed files with 17 additions and 0 deletions

View file

@ -181,6 +181,16 @@ test("Issue #7044, super property access before super() call", () => {
new Foo();
});
test("super property load and store by identifier", () => {
class Foo {
constructor() {
super.bar += "1337";
}
}
new Foo();
});
test("Issue #8574, super property access before super() call", () => {
var hit = false;