Forgot about instanceof.

```
var x = 0;

function Foo() {
    if (new.target) {
        this.i = 0;
    } else {
        // I don't know what class.instance is supposed to mean.
        return x++;
    }
}

Object.setPrototypeOf(Foo, null);
Foo[Symbol.hasInstance] = () => false;
```
_______________________________________________
es-discuss mailing list
[email protected]
https://mail.mozilla.org/listinfo/es-discuss

Reply via email to