diff options
Diffstat (limited to 'js/src/tests/non262/class/derivedConstructorTDZReturnObject.js')
-rw-r--r-- | js/src/tests/non262/class/derivedConstructorTDZReturnObject.js | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/js/src/tests/non262/class/derivedConstructorTDZReturnObject.js b/js/src/tests/non262/class/derivedConstructorTDZReturnObject.js new file mode 100644 index 0000000000..48206a881e --- /dev/null +++ b/js/src/tests/non262/class/derivedConstructorTDZReturnObject.js @@ -0,0 +1,13 @@ +class foo extends null { + constructor() { + // If you return an object, we don't care that |this| went + // uninitialized + return {}; + } +} + +for (let i = 0; i < 1100; i++) + new foo(); + +if (typeof reportCompare === 'function') + reportCompare(0,0,"OK"); |