If you think a bug might affect users in the 57 release, please set the correct tracking and status flags for Release Management.

GetPrototypeFromConstructor needs to retrieve the fallback prototype from the constructor's realm

NEW
Unassigned

Status

()

Core
JavaScript Engine
10 months ago
6 months ago

People

(Reporter: André Bargull, Unassigned)

Tracking

(Blocks: 2 bugs)

Trunk
Points:
---
Dependency tree / graph

Firefox Tracking Flags

(firefox53 affected)

Details

(Reporter)

Description

10 months ago
Test case from test262:
---
var other = newGlobal();

var C = new other.Function();
C.prototype = null;

class B extends function() {} {
  constructor() {
    super();
  }
}

var b = Reflect.construct(B, [], C);

print(Object.getPrototypeOf(b) === other.Object.prototype);
---

Expected: Prints "true"
Actual: Prints "false"


ES2017 spec, 9.1.14 GetPrototypeFromConstructor, step 4.a:
https://tc39.github.io/ecma262/#sec-getprototypefromconstructor
(Reporter)

Updated

10 months ago
Blocks: 1317658
(Reporter)

Updated

6 months ago
Duplicate of this bug: 1346071
You need to log in before you can comment on or make changes to this bug.