Commit Graph

5 Commits

Author SHA1 Message Date
Brian Wilkerson f45f21ae42 Remove the now unnecessary flag from test files
R=asiva@google.com, eernst@google.com

Review URL: https://codereview.chromium.org/2540843002 .
2016-12-02 07:43:05 -08:00
Matthias Hausner 643fdb9dc8 Implement the language change that makes initializing formal parameters visible in the initializer list, but not in the constructor's body.
The feature is enabled with the flag --initializing-formal-access.

BUG=26655, 26656
R=regis@google.com

Review URL: https://codereview.chromium.org/2051213005 .
2016-08-04 11:24:25 -07:00
Erik Ernst c35caf253e 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

Review URL: https://codereview.chromium.org/2029003002 .
2016-06-02 11:09:56 +02:00
Erik Ernst 5b72755837 Revert "Introduces "--initializing-formal-access"."
This reverts commit b80a73775c
because introduced new failures in co19 tests.

Review URL: https://codereview.chromium.org/2021133003 .
2016-05-31 18:03:14 +02:00
Erik Ernst b80a73775c Introduces "--initializing-formal-access".
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

Review URL: https://codereview.chromium.org/2025853002 .
2016-05-31 15:39:02 +02:00