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

Issue 1012783002: Fix renaming of exception variables on left-hand-sides. (Closed)

Created:
5 years, 9 months ago by sigurdm
Modified:
5 years, 9 months ago
Reviewers:
floitsch
CC:
reviews_dartlang.org
Target Ref:
refs/remotes/git-svn
Visibility:
Public.

Description

Fix renaming of exception variables on left-hand-sides. Also fix compound assignments. BUG= R=floitsch@google.com Committed: https://code.google.com/p/dart/source/detail?r=44558

Patch Set 1 #

Patch Set 2 : Remove debug print #

Patch Set 3 : Also fix a too specific type #

Total comments: 6

Patch Set 4 : Address review #

Patch Set 5 : Fix also the dynamic type... #

Unified diffs Side-by-side diffs Delta from patch set Stats (+105 lines, -16 lines) Patch
M pkg/compiler/lib/src/js/rewrite_async.dart View 1 2 3 4 4 chunks +9 lines, -4 lines 0 comments Download
M pkg/js_ast/lib/src/nodes.dart View 1 2 3 1 chunk +1 line, -0 lines 0 comments Download
M tests/compiler/dart2js/async_await_js_transform_test.dart View 2 chunks +80 lines, -1 line 0 comments Download
A + tests/language/async_await_catch_regression_test.dart View 1 chunk +15 lines, -11 lines 0 comments Download

Messages

Total messages: 5 (1 generated)
sigurdm
5 years, 9 months ago (2015-03-16 15:33:54 UTC) #2
floitsch
LGTM. https://codereview.chromium.org/1012783002/diff/40001/pkg/compiler/lib/src/js/rewrite_async.dart File pkg/compiler/lib/src/js/rewrite_async.dart (right): https://codereview.chromium.org/1012783002/diff/40001/pkg/compiler/lib/src/js/rewrite_async.dart#newcode752 pkg/compiler/lib/src/js/rewrite_async.dart:752: // visit the [js.VariableUse] to ensure renaming is ...
5 years, 9 months ago (2015-03-17 17:01:17 UTC) #3
sigurdm
Committed patchset #5 (id:80001) manually as 44558 (presubmit successful).
5 years, 9 months ago (2015-03-18 14:04:53 UTC) #4
sigurdm
5 years, 9 months ago (2015-03-18 14:06:24 UTC) #5
Message was sent while issue was closed.
https://codereview.chromium.org/1012783002/diff/40001/pkg/compiler/lib/src/js...
File pkg/compiler/lib/src/js/rewrite_async.dart (right):

https://codereview.chromium.org/1012783002/diff/40001/pkg/compiler/lib/src/js...
pkg/compiler/lib/src/js/rewrite_async.dart:752: // visit the [js.VariableUse] to
ensure renaming is done correctly.
On 2015/03/17 17:01:17, floitsch wrote:
> Capital "V".

Done.

https://codereview.chromium.org/1012783002/diff/40001/pkg/compiler/lib/src/js...
pkg/compiler/lib/src/js/rewrite_async.dart:753: return new
js.Assignment.compound(visitExpression(leftHandSide),
On 2015/03/17 17:01:17, floitsch wrote:
> Add a comment explaining that it is ok to use compound, even if the `node`
> wasn't a compound assignment.  (At least I hope it is).
> If it's not in the Assignment.compound documentation yet, add it there too.

Done.

https://codereview.chromium.org/1012783002/diff/40001/tests/compiler/dart2js/...
File tests/compiler/dart2js/async_await_js_transform_test.dart (right):

https://codereview.chromium.org/1012783002/diff/40001/tests/compiler/dart2js/...
tests/compiler/dart2js/async_await_js_transform_test.dart:1070: exception =
await 10;
On 2015/03/17 17:01:17, floitsch wrote:
> Apparently catch-variables are supposed to be final.
> http://dartbug.com/19823
> 
> I'm arguing there, that they shouldn't be, but I'm not sure how this impacts
> this test...

This test only contains js-code extended with async/await. So it should not make
a difference.

Powered by Google App Engine
This is Rietveld 408576698