https://codereview.chromium.org/1027283004/diff/530001/src/contexts.h
File src/contexts.h (right):
https://codereview.chromium.org/1027283004/diff/530001/src/contexts.h#newcode594
src/contexts.h:594: : is_strict(language_mode) ||
!IsAccessorFunction(kind)
On 2015/04/07 16:29:57, caitp wrote:
On 2015/04/07 16:18:39, arv wrote:
> I don't understand why accessor functions are special cased here?
>
> Maybe restructure this code to make it clearer what is going on.
It was to avoid breaking the old behaviour.
But I'm not sure, it looks like lexically declared accessors are
always
MethodDefinitions now, so maybe that's a break from ES5? I'm not
really sure if
they should be considered "new syntactic forms" or what
Accessors are considered Methods in ES6 so they have no prototype
property.
I just don't understand why we would use a sloppy map for a strict mode
accessor function?
My suggestion was to rewrite this ternary into if statementest to make
the logic easier to follow.
https://codereview.chromium.org/1027283004/diff/530001/test/webkit/fast/js/Object-getOwnPropertyNames.js
File test/webkit/fast/js/Object-getOwnPropertyNames.js (right):
https://codereview.chromium.org/1027283004/diff/530001/test/webkit/fast/js/Object-getOwnPropertyNames.js#newcode63
test/webkit/fast/js/Object-getOwnPropertyNames.js:63: "parseInt":
"['arguments', 'caller', 'length', 'name']",
On 2015/04/07 16:29:57, caitp wrote:
On 2015/04/07 16:18:40, arv wrote:
> How come this still has arguments and caller?
for whatever reason, "parseInt" and "parseFloat" (and the rest of
these which
still have the properties) are sloppy functions. But I guess that's a
bug.
I think the spec allows this to be implementation defined but it seems
bad that we are inconsistent. This can be fixed in follow up CL. (Please
file bugs so we do not forget.)
https://codereview.chromium.org/1027283004/diff/530001/test/webkit/fast/js/caller-property-expected.txt
File test/webkit/fast/js/caller-property-expected.txt (right):
https://codereview.chromium.org/1027283004/diff/530001/test/webkit/fast/js/caller-property-expected.txt#newcode33
test/webkit/fast/js/caller-property-expected.txt:33: FAIL
nonStrictCaller(strictCallee) should throw TypeError: Type error. Threw
exception TypeError: 'caller' and 'arguments' are restricted function
properties and cannot be accessed in this context..
On 2015/04/07 16:29:57, caitp wrote:
On 2015/04/07 16:18:40, arv wrote:
> Maybe update the test for these?
Okay --- Is there a good reason this test is kept around? It seems
redundant,
and it's no longer in blink's layout tests directory
We can remove it as long as we have other tests that cover the same code
(which I believe we do).
https://codereview.chromium.org/1027283004/
--
--
v8-dev mailing list
v8-dev@googlegroups.com
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 v8-dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.