Commit Graph

4770 Commits

Author SHA1 Message Date
Johnni Winther f10c37b0e5 [cfe] Handle explicit extension instance access.
Including most cases of explicit generic extension instance access.

Change-Id: I43a9d72ef9ddb1dc2cc83f66cb54931b07240d07
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/114859
Reviewed-by: Dmitry Stefantsov <dmitryas@google.com>
Commit-Queue: Johnni Winther <johnniwinther@google.com>
2019-08-30 09:12:41 +00:00
Jens Johansen 751059b246 [CFE] Explicit creation; add test to force it
Change-Id: I5d5598e8ac84cedc5aa6cbadd088c30c5bc4a22f
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/114515
Commit-Queue: Jens Johansen <jensj@google.com>
Reviewed-by: Johnni Winther <johnniwinther@google.com>
2019-08-30 07:41:40 +00:00
danrubel a873bc5db3 fix extension constructor error
This moves another usage of EXTENSION_DECLARES_CONSTRUCTOR into the parser
so that it can be shared by all of CFE.

Change-Id: I3b1502eaf83fdbcc663f4a18d638230e3c5ea925
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/114981
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Dan Rubel <danrubel@google.com>
2019-08-30 00:33:43 +00:00
danrubel 6061906a77 split endMethod into 6 separate events
This updates the parser to detect constructors vs methods
in classes vs mixins vs extensions. Rather than generating a single
endMethod event and require listeners to determine the type of
declaration, the parser now generates different events for
different types of declarations so that listeners can process
each of these different types separately.

In addition, this lays the groundwork for fixing extension declaration
error messages and moving error generation that is duplicated
in the various listeners into the parser.

Change-Id: Ia86a4bf3e6f1442ca4926c754b66e7d6e86fb47d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/114900
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2019-08-30 00:33:43 +00:00
Paul Berry c7f3300448 Flow analysis: begin tracking where variables are written to in closures.
Not yet used.  This will be needed in order to implement the
"writeCaptured" behaviors in the flow analysis spec.

Change-Id: I873f10089a7b93ec5b40d979ddf3a6754e30b181
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/114960
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Paul Berry <paulberry@google.com>
2019-08-29 17:01:24 +00:00
Johnni Winther e3563528e6 [cfe] Add tear off function for extension instance methods.
Change-Id: Ia92640f5dd99cd3eeb5ba737a646472b5f5260a0
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/114844
Commit-Queue: Johnni Winther <johnniwinther@google.com>
Reviewed-by: Dmitry Stefantsov <dmitryas@google.com>
2019-08-29 09:51:53 +00:00
Johnni Winther 63133a2a8c [cfe] Handle extension instance method tearoff
Change-Id: I56f422ed94fbc328030dce1b01df81954969bb01
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/114506
Commit-Queue: Johnni Winther <johnniwinther@google.com>
Reviewed-by: Dmitry Stefantsov <dmitryas@google.com>
2019-08-28 22:16:21 +00:00
Johnni Winther a147d4e8d2 [cfe] Handle simple use of extension instance members
Change-Id: Ic1a949c0dca9327763e01458211e477de13c222f
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/114504
Reviewed-by: Dmitry Stefantsov <dmitryas@google.com>
2019-08-28 22:16:21 +00:00
Dan Rubel e9a44ba6a8 fix extension instance field error
This changes EXTENSION_DECLARES_INSTANCE_FIELD to be a parser error
and moves it into the parser so that it is generated for all of CFE.

See https://github.com/dart-lang/sdk/issues/37945

Change-Id: Ib49d49a20d670e0dd7d9a4cd870237d2cf87dd00
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/114882
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Dan Rubel <danrubel@google.com>
2019-08-28 21:26:31 +00:00
Dan Rubel 15a7b57d8e split endFields into endClass/Mixin/ExtensionFields events
Change-Id: I538d21a595f957ef6080bf3bfe6f0b7299b4bc8d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/114881
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2019-08-28 21:26:31 +00:00
Johnni Winther 57f7941eef [cfe] Remove 'functionNestingLevel' for VariableDeclaration.forValue
The 'functionNestingLevel' property is only needed for mutation and
for-value variables are final.

Change-Id: I970b8b0d9f185ca6fdf9b0599c792672f853105d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/114503
Commit-Queue: Johnni Winther <johnniwinther@google.com>
Reviewed-by: Aske Simon Christensen <askesc@google.com>
2019-08-28 18:50:51 +00:00
Johnni Winther 35382f9b14 [cfe] Always provide a library to the inferrer
This is needed to perform resolution of static extension methods.

Change-Id: Ic3ce046e65a185a4be95151e3d1ec4ad365e35c9
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/114500
Reviewed-by: Aske Simon Christensen <askesc@google.com>
2019-08-28 18:50:51 +00:00
Johnni Winther 999007453a [cfe] Use ExpressionInferenceResult as the main result in the inference visitor
This enables the correction of parent pointers for 'lying' parent pointers
(Judgments that contain nodes but who are not their parents). Long term this can
also be used to replace the slow .replaceChild calls with direct updates in the
visitor.

Change-Id: Ibee7efe815937288dea4dc76d524ef44760a7658
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/114325
Commit-Queue: Johnni Winther <johnniwinther@google.com>
Reviewed-by: Aske Simon Christensen <askesc@google.com>
2019-08-28 14:26:33 +00:00
Jens Johansen 020663cdbc [CFE] Refactor how we get access to BodyBuilder so we can inject a different one in tests
Change-Id: I6c81fe5a954607e1932affa34d844de10b20cb16
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/114510
Reviewed-by: Johnni Winther <johnniwinther@google.com>
Commit-Queue: Jens Johansen <jensj@google.com>
2019-08-28 10:07:12 +00:00
Jens Johansen 10f8a00e9f [CFE] Update language versioning implementation to conform with specification v1.3
In the feature specification v1.2 libraries in a package with a default
version wasn't allowed to specify a language version higher than that.
In v1.3 thats allowed as long as its below the sdk limit.

Change-Id: I85f5c36a9c9c427da03fc540f9175195134ad47f
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/114604
Reviewed-by: Johnni Winther <johnniwinther@google.com>
Commit-Queue: Jens Johansen <jensj@google.com>
2019-08-28 09:30:12 +00:00
danrubel 7b37cddbe8 rename ClassKind to DeclarationKind
... and add DeclarationKind.TopLevel

Change-Id: I631c0173a056e856845f02d4415c11336a796e3c
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/114629
Commit-Queue: Dan Rubel <danrubel@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2019-08-28 00:57:42 +00:00
danrubel 52e732b786 fix constructor in extension error
This changes EXTENSION_DECLARES_CONSTRUCTOR to be a parser error
and moves it into the parser so that it is generated for all of CFE.

See https://github.com/dart-lang/sdk/issues/37945

Change-Id: Iecaf277c63d7791a4b7ac9e6583b5018821d2c18
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/114626
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2019-08-28 00:57:42 +00:00
danrubel 0328e8a7b6 sort ForwardingListener and ForwardingTestListener
Change-Id: Ib94c0c57acb8e3e4271e51205511aee4f087f3fc
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/114641
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Dan Rubel <danrubel@google.com>
2019-08-27 17:54:52 +00:00
danrubel aeb5e732fd split endClass/Mixin/ExtensionFactoryMethod event
This separates an existing parser event into 3 separate events
based upon the enclosing declaration so that listeners
can process them differently in future CLs.

Also address comment in https://dart-review.googlesource.com/c/sdk/+/114564

Change-Id: I07b259d02bd16257edf47eb76cbdd0d022f808dd
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/114640
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2019-08-27 17:54:52 +00:00
Dan Rubel f17d0563fa split class/mixin/extension member parsing
This change makes the parser more aware of what type of member
is being parsed so that proper error messages can be reported
for extension method members in future CLs.

Change-Id: I30002ad1a636b988e59b89d64ba4b0a8ae77c847
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/114564
Reviewed-by: Johnni Winther <johnniwinther@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Dan Rubel <danrubel@google.com>
2019-08-27 14:52:45 +00:00
Aske Simon Christensen 497765f59f [vm] Move VM constant patching before constant evaluation.
This ensures that the VM host endian optimization described in
http://dartbug.com/32836 works properly after the explicit call to
the constant evaluator in the AOT compiler is removed.

Change-Id: I69424c7d27d113a70700a5cdad345bf632272ab6
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/112083
Reviewed-by: Martin Kustermann <kustermann@google.com>
Reviewed-by: Johnni Winther <johnniwinther@google.com>
2019-08-27 14:07:55 +00:00
Aske Simon Christensen a6596cfd40 [cfe] Allow backend target to specify extra libraries to be indexed.
Change-Id: I35e1857bee3a9cc237da7e8bc70d90a1c83e2b1b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/112345
Reviewed-by: Johnni Winther <johnniwinther@google.com>
2019-08-27 14:07:55 +00:00
Aske Simon Christensen 21cf0f5f90 [cfe] Clean out all uses of expired flags.
Change-Id: Ib9096f1a8628d78444bc0847b453dd4032864e09
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/114073
Commit-Queue: Aske Simon Christensen <askesc@google.com>
Reviewed-by: Johnni Winther <johnniwinther@google.com>
2019-08-27 09:24:23 +00:00
Johnni Winther a7b470f51f [cfe] Fix use of ExtensionBuilder.target
Change-Id: If15cf9879aac6e11fe788151742866dfb6620e71
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/114518
Reviewed-by: Johnni Winther <johnniwinther@google.com>
Commit-Queue: Johnni Winther <johnniwinther@google.com>
2019-08-27 08:25:03 +00:00
Johnni Winther 6f2c3977cc [cfe] Add available extensions to Scope.
Change-Id: Ibe087e48c2313fc7b830bac75dcdb51da175edea
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/114324
Reviewed-by: Dmitry Stefantsov <dmitryas@google.com>
2019-08-26 20:54:56 +00:00
Paul Berry b8cb25c96f Flow analysis: shift responsibility for handling final fall-through to FlowAnalysis.
Dart allows the last switch case to "fall through" the end of the
switch statement.  To account for this, we previously required the
caller of FlowAnalysis to calling `handleBreak` at the end of the last
switch case.  (In the analyzer implementation we actually only did
this if the last case was a `default` case, but in practice there was
no observable difference).

This CL shifts the responsibility to FlowAnalysis to handle this
scenario; the caller only needs to call `handleBreak` if there is an
actual break statement present.

Change-Id: Ia0d7abb21d78205f1050873e28b30cddc5fbe344
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/114547
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Paul Berry <paulberry@google.com>
2019-08-26 19:39:00 +00:00
Paul Berry 2011b6fa6b Flow analysis: refactor and unit test switch statement logic.
Responsibility for deciding whether to cancel promotions has been
moved to FlowAnalysis (previously the caller decided).  This should
reduce the risk of the analyzer and front end behaviors diverging.

Also removed an unnecessary argument from
FlowAnalysis.switchStatement_end.

Change-Id: Ib015e4e360e62da7bb267057e4626acaa94e9e74
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/114541
Commit-Queue: Paul Berry <paulberry@google.com>
Reviewed-by: Dan Rubel <danrubel@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
2019-08-26 16:11:25 +00:00
Johnni Winther 103a43dd73 [cfe] Towards deprecating Builder.target
- deprecates 'target' on LibraryBuilder, ClassBuilder, ExtensionBuilder,
  TypeAliasBuilder, and TypeVariableBuilder.
- prepares for deprecation of 'target' on MemberBuilder,
  VariableBuilder, and FormalParameterBuilder

Change-Id: Ic04c533eb5443c7b7c6413e48f399450d1ebe43a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/113440
Commit-Queue: Johnni Winther <johnniwinther@google.com>
Reviewed-by: Aske Simon Christensen <askesc@google.com>
2019-08-26 12:52:10 +00:00
Paul Berry 30e4092d27 Flow analysis: handle empty for-loop conditions directly in FlowAnalysis.
Previously the client was required to create a synthetic `true`
literal.  The client may still do that (it's equivalent), but it's no
longer necessary.

Change-Id: Iffa12769b542678dab6cd4b5583d7058b41aebd1
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/114342
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
2019-08-23 16:19:49 +00:00
Johnni Winther 00610ec765 [cfe] Return inferred type from inference visitor
Change-Id: I69f7d1283c52e66c17153f4012c712358d64c450
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/114200
Reviewed-by: Dmitry Stefantsov <dmitryas@google.com>
Commit-Queue: Johnni Winther <johnniwinther@google.com>
2019-08-23 11:52:38 +00:00
Johnni Winther 16a4ee0eb5 [cfe] Use fileOffset instead of Token in createArguments
This is a step towards decoupling Token from Forest. We should be able to
create nodes without tokens an still provide offsets.

Change-Id: Ifd2499435a12d0b54db1cc374d71cbc51d187f98
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/114071
Reviewed-by: Dmitry Stefantsov <dmitryas@google.com>
2019-08-23 11:52:38 +00:00
Johnni Winther 8c9d6c1c68 [cfe] Use ObjectAccessTarget as the result for object access resolution
Change-Id: Id6c9fcccf2424e6b6596c0c6937de802176fe818
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/113996
Reviewed-by: Dmitry Stefantsov <dmitryas@google.com>
2019-08-23 11:52:38 +00:00
Paul Berry 5fb29b6a8d Flow analysis: allow sets of referenced variables to be any iterable.
Change-Id: I999d06deaf5764ea422cf5bbbb4b9c1cb1cddcfe
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/114080
Commit-Queue: Paul Berry <paulberry@google.com>
Reviewed-by: Dan Rubel <danrubel@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
2019-08-23 11:07:58 +00:00
Paul Berry 1f9dd21940 Flow analysis: create the VariableModel data structure.
In the long term we want to track a lot of information about each
variable; currently we are only tracking the promoted type.

Change-Id: Ibdf90e0db524b4b87eb23921529ff2a65a927f9f
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/113748
Reviewed-by: Dan Rubel <danrubel@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
2019-08-23 11:07:58 +00:00
Jens Johansen 74e09abc6e [CFE] Remove/move file that wasn't needed by frontend; cleanup pubspec.yaml a bit
Change-Id: I204b844e7f1cb892a529bca3a13017ed836275f8
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/114074
Reviewed-by: Paul Berry <paulberry@google.com>
Commit-Queue: Jens Johansen <jensj@google.com>
2019-08-23 07:42:03 +00:00
Jens Johansen bd681ea660 [CFE] Move testing out of lib/src/fasta
Change-Id: I477892fa9268ab3715152c0253dd65a1c1541c1e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/114072
Reviewed-by: Johnni Winther <johnniwinther@google.com>
Commit-Queue: Jens Johansen <jensj@google.com>
2019-08-23 06:20:03 +00:00
Alexander Markov 5e428ed638 [vm/bytecode] Fixes for expression evaluation
* Set parent for TypeParameters created in createExpressionEvaluationComponent.

* Resolve references from bytecode to an expression evaluation class
  using real class. Expression evaluation class could be referenced
  from type parameters.

* Avoid registering expression evaluation classes in hierarchy. They
  shouldn't be discovered through direct subclasses or implementors,
  as expression evaluation classes don't have cids.

* Add :function_type_arguments_var local variable to bytecode local
  variables info, so expression evaluation can find function type
  arguments which are in scope.

Change-Id: I515431a989b4d02af4ecf90579931dd59d3acadd
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/114182
Reviewed-by: Régis Crelier <regis@google.com>
Commit-Queue: Alexander Markov <alexmarkov@google.com>
2019-08-22 22:53:12 +00:00
Aske Simon Christensen 95c9f732de Expire spread and control-flow collection flags.
Change-Id: I59fe3ad2bdd90681e6d40dc39f04a0e53125e707
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/113989
Reviewed-by: Paul Berry <paulberry@google.com>
Commit-Queue: Aske Simon Christensen <askesc@google.com>
2019-08-22 10:52:51 +00:00
Jens Johansen 40589f80aa [CFE] Fourth batch of fixes for requiring explicit types
Change-Id: I13f62232287b84cc82da2bbb0cee4b4d337de8ad
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/113992
Commit-Queue: Jens Johansen <jensj@google.com>
Reviewed-by: Johnni Winther <johnniwinther@google.com>
2019-08-22 07:08:27 +00:00
Paul Berry 51cd16ecf0 Flow analysis: support for and for-in elements in collections.
Change-Id: Ia73c68c2b8a57c62ce2b4984184cf8a712b554af
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/113944
Commit-Queue: Paul Berry <paulberry@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Phil Quitslund <pquitslund@google.com>
2019-08-21 21:57:54 +00:00
Aske Simon Christensen 5905fe41a9 [CFE] Explicit return types and overrides in constant evaluator
Change-Id: Ibdba0689a7de58f3ab999d10d963dac43dbfc1e4
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/113984
Commit-Queue: Aske Simon Christensen <askesc@google.com>
Reviewed-by: Jens Johansen <jensj@google.com>
2019-08-21 12:25:32 +00:00
Dan Rubel 3e69627752 Fix type argument parsing crash
Fix https://github.com/dart-lang/sdk/issues/37706

Change-Id: Ifc54c3fa4f57c772f8059d59e0265c4677a400fb
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/113860
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2019-08-20 20:04:19 +00:00
Dan Rubel e2777454cc Fix dartfmt bug
... by changing ANNOTATION_WITH_TYPE_ARGUMENTS to be a syntax error

Fix https://github.com/dart-lang/dart_style/issues/836

Change-Id: I2ac1b1105b817b6728ecc3d73875581a9cf65861
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/113760
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2019-08-20 20:04:19 +00:00
Jens Johansen 363ae34c55 [CFE] Third batch of fixes for requiring explicit types
Change-Id: Ie4c8e66acf942901602c91819640967e49044233
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/113822
Reviewed-by: Johnni Winther <johnniwinther@google.com>
Commit-Queue: Jens Johansen <jensj@google.com>
2019-08-20 13:11:12 +00:00
Dan Rubel f5f942684b Fix invalid literal list element crash
Fix https://github.com/dart-lang/sdk/issues/37697

Change-Id: Icefae7ca0c0f6b0d317c6aa48039fa6e6967409d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/113705
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Dan Rubel <danrubel@google.com>
2019-08-20 12:03:12 +00:00
Johnni Winther d153e98447 Revert "[cfe] Gather constraints from both possibilities for FutureOr"
This reverts commit 00e9561798.

Original change's description:
> [cfe] Gather constraints from both possibilities for FutureOr
> 
> Closes #37778.
> 
> Bug: http://dartbug.com/37778
> Change-Id: Ic06da9cf4e24e397e1f2a180b743190a4165dc3e
> Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/113033
> Commit-Queue: Johnni Winther <johnniwinther@google.com>
> Reviewed-by: Johnni Winther <johnniwinther@google.com>

TBR=dmitryas@google.com,johnniwinther@google.com

Change-Id: I64677971c865180334958de13d2d82fec3daec85
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: http://dartbug.com/37778
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/113821
Reviewed-by: Johnni Winther <johnniwinther@google.com>
Commit-Queue: Johnni Winther <johnniwinther@google.com>
2019-08-20 10:57:52 +00:00
Jens Johansen 10e63b7840 [CFE] Get fragment from default package - use language version if any
Language versioning specifies that an empty-name-entry in .packages
specifies a sort of "default package" that a non-package file should
pretend to be a part of "for any purpose where that matters,
including choosing the default language level."

Change-Id: I16f4b2f5e4d3ca1e82d2189321e2be5c43e3b260
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/112089
Commit-Queue: Jens Johansen <jensj@google.com>
Reviewed-by: Johnni Winther <johnniwinther@google.com>
2019-08-20 09:06:32 +00:00
Johnni Winther 00e9561798 [cfe] Gather constraints from both possibilities for FutureOr
Closes #37778.

Bug: http://dartbug.com/37778
Change-Id: Ic06da9cf4e24e397e1f2a180b743190a4165dc3e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/113033
Commit-Queue: Johnni Winther <johnniwinther@google.com>
Reviewed-by: Johnni Winther <johnniwinther@google.com>
2019-08-20 08:43:22 +00:00
Dan Rubel bb076a20c5 Fix unsupported initializer exception
... and add a new ParserErrorCode.INVALID_INITIALIZER error code

Fix https://github.com/dart-lang/sdk/issues/37693

Change-Id: I0a30ad97f90aab35cd3af76d1546e1e78f1de2db
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/113703
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Dan Rubel <danrubel@google.com>
2019-08-19 19:55:12 +00:00
Dan Rubel 3568f78fe7 ensure super constructor invocation param list not null during recovery
Fix https://github.com/dart-lang/sdk/issues/37735

Change-Id: I727cd7aeb141c5abb779b3c15f338f3d43f6541f
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/113702
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Dan Rubel <danrubel@google.com>
2019-08-19 18:34:32 +00:00