Commit graph

5 commits

Author SHA1 Message Date
Johnni Winther 87906e832b [cfe] Implemenet abstract fields errors
Change-Id: I78900228ee72d914844e9fe11fcfb2cdef952ece
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/154881
Reviewed-by: Dmitry Stefantsov <dmitryas@google.com>
Commit-Queue: Johnni Winther <johnniwinther@google.com>
2020-07-20 12:05:54 +00:00
Erik Ernst 7c66851efe Adjust external_fields_test to expect specified outcome
Change-Id: Ie90ad6b1bb98930bb803c64ca2b7037681a88857
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/154690
Reviewed-by: Nicholas Shahan <nshahan@google.com>
Commit-Queue: Erik Ernst <eernst@google.com>
2020-07-17 17:51:46 +00:00
Johnni Winther 92f4eb58c8 [cfe] Support abstract fields
Only positive implementation, no error states are checked yet.

Change-Id: Iad79da1dd7e8be9229ee9d47c5301d39ebc3debc
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/154003
Commit-Queue: Johnni Winther <johnniwinther@google.com>
Reviewed-by: Dmitry Stefantsov <dmitryas@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2020-07-16 10:13:23 +00:00
Erik Ernst efb1143943 Fix typos in CL 148324
CL 148324 'For external/abstract fields: add tests and update Dart.g'
contained a couple of typos, this CL corrects them.

Change-Id: I6ee9b769c8b23e299b13cbb5d4ba38cbfec7656f
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/153145
Reviewed-by: Lasse R.H. Nielsen <lrn@google.com>
Commit-Queue: Erik Ernst <eernst@google.com>
2020-07-09 14:00:02 +00:00
Erik Ernst f4d7951a88 For external/abstract fields: add tests and update Dart.g
This CL adds tests in language/external_abstract_fields, testing the
support for abstract instance variables, and for external top-level,
class, and instance variables. It is tested that the syntax of
supported declarations is accepted, and a number of non-supported
forms are rejected, and abstract fields are tested at run time as well.

The implementation of external fields is provided by an implementation
specific mechanism, and no tests are added for any such mechanisms
(that is, with external fields we only test errors).

This CL also updates the spec grammar Dart.g to include grammar
rules for the new kinds of declarations, and it has been verified that
the new tests are passing, respectively cause syntax errors, as
indicated in the test files.

The tests are a further development of the ones in
https://dart-review.googlesource.com/c/sdk/+/145862.

Change-Id: I13be746a05d5acf0117d8cb22151bd9863a71a78
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/148324
Commit-Queue: Erik Ernst <eernst@google.com>
Reviewed-by: Lasse R.H. Nielsen <lrn@google.com>
2020-07-02 13:39:39 +00:00