On 2015/02/09 16:31:44, Dmitry Lomov (chromium) wrote:
PTAL before platform ports.
The idea is: subclass constructors (the ones that have 'extends') have an
extra
argument (which is new.target). This is reflected in the count of formal
arguments as reported by SharedFunctionInfo, so argument adaptor frames
etc.
are
set correctly.
The only way those functions can be gainfully invoked is via
their 'construct'
stub, and their special construct stub sets up arguemnts correctly. If you
call
them via [[Call]] the arguments will be bound all wrong, but it does not
matter
since [[Call]] throws.
Ideas for more tests or what can go wrong welcome
That is a good idea.
Things that might go wrong:
- Usage of arguments
- Special cases of arguments in apply etc
- Function instance length property
- Rest & optional parameters once implemented
- Bound function [[Construct]]
https://codereview.chromium.org/908883002/
--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
---
You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.