keuchel@chromium.org
d434d3158c
Detect conflicting variable bindings in harmony mode.
...
BUG=
TEST=mjsunit/harmony/block-conflicts.js
Review URL: http://codereview.chromium.org/7756014
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9102 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-01 12:31:18 +00:00
keuchel@chromium.org
42388ad5c7
Temporal dead zone behaviour for let bindings.
...
BUG=
TEST=mjsunit/harmony/block-let-semantics.js
Review URL: http://codereview.chromium.org/7671042
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9070 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-08-30 11:23:57 +00:00
mstarzinger@chromium.org
c6e42e1bfa
Fix initial prototype of WeakMap function.
...
The bootstrapper accidentally overwrote the constructor property of the Object
prototype because it used initial_object_prototype() as prototype for WeakMap.
Unfortunately this is not possible for experimental natives because they are
installed after the snapshot initialization finished.
R=erik.corry@gmail.com
TEST=mjsunit/mirror-object,mjsunit/harmony/weakmaps
Review URL: http://codereview.chromium.org/7624041
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9067 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-08-30 09:35:20 +00:00
keuchel@chromium.org
c6c504f8b6
Parse harmony let declarations.
...
Implementation of the harmony block scoped let bindings as proposed here:
http://wiki.ecmascript.org/doku.php?id=harmony:block_scoped_bindings
Changes to the syntax are explained there. They are active under the
harmony_block_scoping_ flag in the parser.
Review URL: http://codereview.chromium.org/7616009
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8944 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-08-16 14:24:12 +00:00
mstarzinger@chromium.org
d640d8d913
Fix issue with prototype of WeakMap constructor.
...
The WeakMap constructor didn't have a unique prototype, so it shared one with
Object. All WeakMap functions (including "get" and "set") were installed on
that prototype.
R=rossberg@chromium.org
BUG=v8:1617
TEST=mjsunit/harmony/weakmaps
Review URL: http://codereview.chromium.org/7658008
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8941 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-08-16 12:09:47 +00:00
keuchel@chromium.org
3c7ca304fe
Preliminary code for block scopes and block contexts.
...
BUG=
TEST=
Review URL: http://codereview.chromium.org/7549008
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8911 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-08-11 16:29:28 +00:00
rossberg@chromium.org
bd18514972
Implement Harmony semantics for typeof null (behind a flag).
...
Harmony is intended to make typeof null === "null". This may
break existing programs. Implementing it will allow us to run
some tests on the actual web.
R=kmillikin@chromium.org
BUG=
TEST=
Review URL: http://codereview.chromium.org/7598030
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8876 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-08-10 12:12:06 +00:00
mstarzinger@chromium.org
9b826964f2
Additional functions to Harmony weak maps API.
...
R=rossberg@chromium.org
BUG=v8:1565
TEST=mjsunit/harmony/weakmaps
Review URL: http://codereview.chromium.org/7572013
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8825 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-08-04 11:13:15 +00:00
mstarzinger@chromium.org
b05ff5e0b9
Prototype of mark-and-compact support for Harmony weak maps.
...
R=vegorov@chromium.org
BUG=v8:1565
TEST=cctest/test-weakmaps
Review URL: http://codereview.chromium.org/7553012
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8817 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-08-03 12:48:30 +00:00
mstarzinger@chromium.org
2bb7c74f80
Preliminary Harmony weak maps API implementation.
...
R=rossberg@chromium.org ,danno@chromium.org
BUG=v8:1565
TEST=mjsunit/harmony/weakmaps
Review URL: http://codereview.chromium.org/7529007
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8811 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-08-03 11:55:13 +00:00
rossberg@chromium.org
3f5bc11c55
Implement Object.prototype.{hasOwnProperty, propertyIsEnumerable} for proxies.
...
Refactor trap invocation.
Test other Object.prototype functionality for proxies.
R=ager@chromium.org
BUG=v8:1543
TEST=
Review URL: http://codereview.chromium.org/7436004
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8707 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-07-21 11:20:27 +00:00
rossberg@chromium.org
f7ff89ea02
Implement `in' for proxies.
...
R=ager@chromium.org
BUG=v8:1543
TEST=
Review URL: http://codereview.chromium.org/7390028
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8681 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-07-19 09:38:59 +00:00
rossberg@chromium.org
5e62e325ac
Implement sealing, freezing, and related functions for proxies.
...
R=ager@chromium.org
BUG=v8:1543
TEST=
Review URL: http://codereview.chromium.org/7391001
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8673 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-07-18 13:04:52 +00:00
rossberg@chromium.org
75a2c49c1d
Implement delete trap for proxies.
...
R=ager@chromium.org
BUG=1543
TEST=
Review URL: http://codereview.chromium.org/7369001
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8660 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-07-15 09:10:20 +00:00
rossberg@chromium.org
ddb782dcb8
Implement Object.getOwnPropertyDescriptor for proxies.
...
Fix bug in compilation of calls with proxy receivers.
R=kmillikin@chromium.org ,ager@chromium.org
BUG=
TEST=
Review URL: http://codereview.chromium.org/7237050
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8630 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-07-13 11:57:15 +00:00
rossberg@chromium.org
6e2da733da
Implement Object.keys for proxies.
...
R=kmillikin@chromium.org ,ager@chromium.org
BUG=
TEST=
Review URL: http://codereview.chromium.org/7321004
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8626 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-07-13 11:01:17 +00:00
rossberg@chromium.org
58b913f9f0
Implement Object.defineProperty for proxies.
...
R=kmillikin@chromium.org
BUG=
TEST=
Review URL: http://codereview.chromium.org/7314003
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8564 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-07-07 12:41:20 +00:00
ager@chromium.org
22b5dfd395
Reapply: "Make instanceof and Object.getPrototypeOf work for proxies,
...
plus a few other tweaks."
The problem with the original patch was that it did not take hidden
prototype objects into account in Runtime_GetPrototype.
R=kmillikin@chromium.org ,rossberg@chromium.org
TEST=es5conform
Review URL: http://codereview.chromium.org/7056041
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8164 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-06-03 10:15:49 +00:00
ager@chromium.org
ece7700d7c
Revert "Make instanceof and Object.getPrototypeOf work for proxies, plus a few other tweaks."
...
This change caused errors in es5conform tests for getPrototypeOf.
TBR=rossberg@chromium.org
BUG=
TEST=
Review URL: http://codereview.chromium.org/7109004
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8159 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-06-02 10:12:00 +00:00
rossberg@chromium.org
2255860992
Make instanceof and Object.getPrototypeOf work for proxies, plus a few other tweaks.
...
R=kmillikin@chromium.org
Review URL: http://codereview.chromium.org/7080053
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8150 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-06-01 17:44:08 +00:00
rossberg@chromium.org
670f947a5c
Implement set trap for proxies, and revamp class hierarchy in preparation:
...
- Introduce a class JSReceiver, that is a common superclass of JSObject and
JSProxy. Use JSReceiver where appropriate (probably lots of places that we
still have to migrate, but we will find those later with proxy test suite).
- Move appropriate methods to JSReceiver class (SetProperty,
GetPropertyAttribute, Get/SetPrototype, Lookup, and so on).
- Introduce new JSFunctionProxy subclass of JSProxy. Currently only a stub.
- Overhaul enum InstanceType:
* Introduce FIRST/LAST_SPEC_OBJECT_TYPE that ranges over all types that
represent JS objects, and use that consistently to check language types.
* Rename FIRST/LAST_JS_OBJECT_TYPE and FIRST/LAST_FUNCTION_CLASS_TYPE
to FIRST/LAST_[NON]CALLABLE_SPEC_OBJECT_TYPE for clarity.
* Eliminate the overlap over JS_REGEXP_TYPE.
* Also replace FIRST_JS_OBJECT with FIRST_JS_RECEIVER, but only use it where
we exclusively talk about the internal representation type.
* Insert JS_PROXY and JS_FUNCTION_PROXY in the appropriate places.
- Fix all checks concerning classification, especially for functions, to
use the CALLABLE_SPEC_OBJECT range (that includes funciton proxies).
- Handle proxies in SetProperty (that was the easiest part :) ).
- A few simple test cases.
R=kmillikin@chromium.org
Review URL: http://codereview.chromium.org/6992072
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8126 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-05-31 16:38:40 +00:00