v8/test/mjsunit/es6/regress
dslomov cf53fed972 Handle the case when derived constructor is [[Call]]ed with 0 args.
ArgumentsAdaptorStub for derived constructor (the one that needs
new.target) works in this way:
 - If the constructor is invoked via the Construct stub, we know that
   actual arguments always include new.target. ``arguments`` object
   however should not include a new.target, therefore we remove it.
   We achieve this by decrementing the argument count.
 - If the constructor is invoked as a call, we do not care for a correct
   ``arguments`` array since the constructor will immediately throw on
   entrance.
The bug is that the call could actually pass 0 actual arguments, but I
decrement unconditionally :(. The fix is to detect this case and avoid
decrementing. ``arguments`` is bogus, but it is ok as constructor
throws.

Long-term we should just remove mucking about with arguments for
new.target and just get it from the stack.

R=arv@chromium.org,rossberg@chromium.org
BUG=chromium:474783
LOG=Y

Review URL: https://codereview.chromium.org/1126783003

Cr-Commit-Position: refs/heads/master@{#28242}
2015-05-05 19:57:04 +00:00
..
regress-2034.js Re^3-land "Ship promises and weak collections" 2014-05-06 14:48:34 +00:00
regress-2156.js Re^3-land "Ship promises and weak collections" 2014-05-06 14:48:34 +00:00
regress-2186.js Enable ES6 Map and Set by default 2014-08-05 19:37:32 +00:00
regress-2243.js Remove --harmony-scoping flag. 2015-03-13 15:15:57 +00:00
regress-2322.js Remove --harmony-scoping flag. 2015-03-13 15:15:57 +00:00
regress-2506.js Remove --harmony-scoping flag. 2015-03-13 15:15:57 +00:00
regress-2681.js Enable ES6 generators 2014-09-16 12:30:39 +00:00
regress-2691.js Enable ES6 generators 2014-09-16 12:30:39 +00:00
regress-2829.js Re^3-land "Ship promises and weak collections" 2014-05-06 14:48:34 +00:00
regress-2858.js Remove --harmony-scoping flag. 2015-03-13 15:15:57 +00:00
regress-3280.js Enable ES6 generators 2014-09-16 12:30:39 +00:00
regress-3426.js Remove --harmony-scoping flag. 2015-03-13 15:15:57 +00:00
regress-3683.js Remove --harmony-scoping flag. 2015-03-13 15:15:57 +00:00
regress-3741.js Remove --harmony-scoping flag. 2015-03-13 15:15:57 +00:00
regress-3902.js Make generator constructors configurable 2015-02-19 11:30:33 +00:00
regress-3938.js [es6] Fix for-const loops 2015-03-03 18:34:40 +00:00
regress-347906.js [harmony] Move some regression tests to the right place 2015-03-20 11:03:14 +00:00
regress-411237.js [harmony] Move some regression tests to the right place 2015-03-20 11:03:14 +00:00
regress-468661.js Stack allocate lexical locals + hoist stack slots 2015-04-22 13:22:18 +00:00
regress-474783.js Handle the case when derived constructor is [[Call]]ed with 0 args. 2015-05-05 19:57:04 +00:00
regress-cr372788.js Drop thenable coercion cache 2014-05-14 10:44:34 +00:00
regress-crbug-248025.js Enable ES6 iteration by default 2014-08-07 16:42:14 +00:00
regress-crbug-346141.js Enable ES6 Symbols by default 2014-08-04 18:17:54 +00:00