Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(137)

Issue 382893003: Implement basic code generation for arrow functions (Closed)

Created:
6 years, 5 months ago by aperez
Modified:
6 years, 5 months ago
CC:
v8-dev
Project:
v8
Visibility:
Public.

Description

Implement basic code generation for arrow functions Implements code generation for arrow functions by desugaring them into a FunctionLiteral. For the moment, a normal FUNCTION_SCOPE is used, so "this" and "arguments" behave as in normal functions. Implementing the correct scoping rules is to be done later on. BUG=v8:2700 LOG= R=rossberg@chromium.org Committed: https://code.google.com/p/v8/source/detail?r=22495

Patch Set 1 #

Total comments: 5

Patch Set 2 : Rebased, and fixed nits #

Patch Set 3 : Make sure build succeeds with werror=yes #

Patch Set 4 : Test failures fixed, some minor corrections #

Unified diffs Side-by-side diffs Delta from patch set Stats (+243 lines, -151 lines) Patch
M src/ast.h View 6 chunks +31 lines, -42 lines 0 comments Download
M src/compiler.cc View 1 2 3 3 chunks +7 lines, -11 lines 0 comments Download
M src/factory.h View 1 2 1 chunk +2 lines, -5 lines 0 comments Download
M src/factory.cc View 1 2 2 chunks +4 lines, -5 lines 0 comments Download
M src/full-codegen.cc View 1 2 1 chunk +3 lines, -2 lines 0 comments Download
M src/objects.h View 1 2 3 2 chunks +4 lines, -0 lines 0 comments Download
M src/objects-inl.h View 1 2 3 1 chunk +1 line, -0 lines 0 comments Download
M src/parser.h View 1 2 3 2 chunks +6 lines, -1 line 0 comments Download
M src/parser.cc View 1 2 3 4 chunks +28 lines, -39 lines 0 comments Download
M src/preparser.h View 1 2 3 7 chunks +46 lines, -18 lines 0 comments Download
M src/preparser.cc View 2 chunks +6 lines, -3 lines 0 comments Download
M src/runtime.h View 1 2 3 1 chunk +1 line, -0 lines 0 comments Download
M src/runtime.cc View 1 2 3 1 chunk +8 lines, -0 lines 0 comments Download
M src/v8natives.js View 1 2 3 1 chunk +4 lines, -0 lines 0 comments Download
M test/cctest/test-parsing.cc View 1 2 3 6 chunks +41 lines, -23 lines 0 comments Download
A test/mjsunit/harmony/arrow-functions.js View 1 1 chunk +48 lines, -0 lines 0 comments Download
M tools/generate-runtime-tests.py View 1 2 3 2 chunks +3 lines, -2 lines 0 comments Download

Messages

Total messages: 10 (0 generated)
rossberg
LGTM, only nits https://codereview.chromium.org/382893003/diff/1/src/objects.h File src/objects.h (right): https://codereview.chromium.org/382893003/diff/1/src/objects.h#newcode7279 src/objects.h:7279: // Indicated that this function is ...
6 years, 5 months ago (2014-07-14 13:55:47 UTC) #1
aperez
On 2014/07/14 13:55:47, rossberg wrote: > LGTM, only nits The new patch set should have ...
6 years, 5 months ago (2014-07-14 18:20:40 UTC) #2
rossberg
Hm, I'm getting this error: ../src/ast.h:2435:56: error: ‘body’ may be used uninitialised in this function ...
6 years, 5 months ago (2014-07-16 09:37:41 UTC) #3
aperez
On 2014/07/16 09:37:41, rossberg wrote: > Hm, I'm getting this error: > > ../src/ast.h:2435:56: error: ...
6 years, 5 months ago (2014-07-16 11:18:52 UTC) #4
aperez
On 2014/07/16 11:18:52, aperez wrote: > Ah, let me do a build with GCC and ...
6 years, 5 months ago (2014-07-16 11:42:14 UTC) #5
rossberg
On 2014/07/16 11:42:14, aperez wrote: > On 2014/07/16 11:18:52, aperez wrote: > > > Ah, ...
6 years, 5 months ago (2014-07-16 11:59:42 UTC) #6
aperez
On 2014/07/16 11:59:42, rossberg wrote: > On 2014/07/16 11:42:14, aperez wrote: > > On 2014/07/16 ...
6 years, 5 months ago (2014-07-19 20:33:27 UTC) #7
aperez
On 2014/07/19 20:33:27, aperez wrote: > On 2014/07/16 11:59:42, rossberg wrote: > > On 2014/07/16 ...
6 years, 5 months ago (2014-07-19 20:33:35 UTC) #8
aperez
On 2014/07/19 20:33:35, aperez wrote: > On 2014/07/19 20:33:27, aperez wrote: > > On 2014/07/16 ...
6 years, 5 months ago (2014-07-19 20:34:22 UTC) #9
rossberg
6 years, 5 months ago (2014-07-21 09:58:15 UTC) #10
Message was sent while issue was closed.
Committed patchset #4 manually as r22495 (presubmit successful).

Powered by Google App Engine
This is Rietveld 408576698