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

Issue 2029003002: Introduces "--initializing-formal-access". (Closed)

Created:
4 years, 6 months ago by eernst
Modified:
4 years, 6 months ago
CC:
reviews_dartlang.org, floitsch
Base URL:
https://github.com/dart-lang/sdk.git@master
Target Ref:
refs/heads/master
Visibility:
Public.

Description

Introduces "--initializing-formal-access". This CL is an adjusted version of CL 2025853002, adding updates to `InitializingFormalElementZ` to match the updates applied to `InitializingFormalElementX`, and adding the new option to the `MessageKind.DUPLICATE_DEFINITION` example. Description from 2025853002: This CL adjusts the treatment of initializing formals, such that they can be used in initializers and in constructor bodies. E.g., `x` can be used as in `C(this.x) : y = x { var z = x + 2; }`. It hides the new feature under the option '--initializing-formal-access' which is used in the test 'initializing_formal_access_test.dart'. It also adds an `example` test to `MessageKind.DUPLICATE_DEFINITION` to verify that name clashes among initializing formals and other parameters are detected (which was previously not the case). Finally, it fixes a typo in a comment, `InitializingFormalParameter` -> `InitializingFormalElement`. R=johnniwinther@google.com Committed: https://github.com/dart-lang/sdk/commit/c35caf253efcd497dcdfc0603a56b8bdd34f2d07

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+81 lines, -6 lines) Patch
M pkg/compiler/lib/src/commandline_options.dart View 1 chunk +1 line, -0 lines 0 comments Download
M pkg/compiler/lib/src/compile_time_constants.dart View 1 chunk +3 lines, -0 lines 0 comments Download
M pkg/compiler/lib/src/dart2js.dart View 1 chunk +1 line, -0 lines 0 comments Download
M pkg/compiler/lib/src/diagnostics/messages.dart View 2 chunks +10 lines, -0 lines 0 comments Download
M pkg/compiler/lib/src/elements/elements.dart View 2 chunks +2 lines, -2 lines 0 comments Download
M pkg/compiler/lib/src/elements/modelx.dart View 1 chunk +5 lines, -1 line 0 comments Download
M pkg/compiler/lib/src/options.dart View 5 chunks +9 lines, -0 lines 0 comments Download
M pkg/compiler/lib/src/resolution/members.dart View 3 chunks +8 lines, -1 line 0 comments Download
M pkg/compiler/lib/src/serialization/modelz.dart View 2 chunks +4 lines, -1 line 0 comments Download
M pkg/compiler/lib/src/typechecker.dart View 1 chunk +4 lines, -1 line 0 comments Download
A tests/language/initializing_formal_access_test.dart View 1 chunk +28 lines, -0 lines 0 comments Download
M tests/language/language.status View 1 chunk +3 lines, -0 lines 0 comments Download
M tests/language/language_analyzer2.status View 1 chunk +3 lines, -0 lines 0 comments Download

Messages

Total messages: 8 (3 generated)
eernst
This CL is a corrected version of the previously landed and reverted CL 2025853002 (updates ...
4 years, 6 months ago (2016-06-01 13:24:27 UTC) #2
Johnni Winther
lgtm
4 years, 6 months ago (2016-06-02 07:39:25 UTC) #3
eernst
Committed patchset #1 (id:1) manually as c35caf253efcd497dcdfc0603a56b8bdd34f2d07 (presubmit successful).
4 years, 6 months ago (2016-06-02 09:10:12 UTC) #5
floitsch
Please add a test that captures the variable and verifies that it isn't the field. ...
4 years, 6 months ago (2016-06-02 11:59:49 UTC) #7
eernst
4 years, 6 months ago (2016-06-02 14:18:48 UTC) #8
Message was sent while issue was closed.
On 2016/06/02 11:59:49, floitsch wrote:
> Please add a test that captures the variable and verifies that it isn't the
> field.
> Also add a test that ensures that the variable is final.

Working on a new CL which will do that.

Powered by Google App Engine
This is Rietveld 408576698