Commit Graph

5945 Commits

Author SHA1 Message Date
Dan Rubel 6edefda065 cleanup token rewriter and clients
Change-Id: I05f3549c37abccaa7ce7119c0b9d3a084a381f80
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/103500
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2019-05-22 22:11:40 +00:00
Konstantin Shcheglov 4ccf7b865e Don't set type for StringLiteral(s) in directives.
R=brianwilkerson@google.com

Change-Id: Ie34d481c5ef07008d38aee1e89f1beb8a313590a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/103460
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2019-05-22 20:37:31 +00:00
Sam Rawlins b22cd05c51 Reland fix for #28233: add hint for missing returns to function expressions
The bulk of this change is actually correcting missing returns in the Dart SDK.

Bug: https://github.com/dart-lang/sdk/issues/28233
Change-Id: I52bcbc6c6f4a129d3fc22003f4448a7c3d4487ad
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/100301
Commit-Queue: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Johnni Winther <johnniwinther@google.com>
2019-05-22 18:12:30 +00:00
Brian Wilkerson 7d1b54bd47 Add a minimal implementation of ExtensionDeclaration
Change-Id: I5a556ea1819b38a3130e801a3cbc4bcbad98dcdd
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/103380
Reviewed-by: Paul Berry <paulberry@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
2019-05-22 12:43:02 +00:00
Konstantin Shcheglov 4317c5ff3f Don't set elements and types during AstRewriteVisitor.
Resolution is incomplete at the time when we perform rewriting.
For example, in `C<int>` the type of `int` is not set, so we get
incomplete InterfaceType of `C` with `null` as the type argument.
This was crashing summary2 in one situation internally.

R=brianwilkerson@google.com

Change-Id: Ifcff68f007a90b5694cf3e4e4d3825309c04e2b8
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/103382
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2019-05-22 03:29:17 +00:00
Mike Fairhurst 6457ac1d4b Test potentially-nullable access errors
Change-Id: Ia166dbb6fb353120e30555f60b7bea186537b05b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/102242
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2019-05-22 03:17:00 +00:00
danrubel add95652d2 fix AstBuilder invalid getter recovery
This fixes the Astbuilder recovery when encountering "get <identifier> :"
in a class body to build a method node rather than a constructor node.

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

Change-Id: I48242838d72c3a6c18e78a469b6e07fd1481d0c4
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/103260
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Dan Rubel <danrubel@google.com>
2019-05-22 00:28:55 +00:00
Konstantin Shcheglov e20da9c220 Fix order of resolving / writing / reading of function / method declarations.
Now that we assign indexes to occurred GenericFunctionType nodes, we
need to make the order consistent across all visitors.

R=brianwilkerson@google.com

Change-Id: Ifc9c7bfa35612cef235f000f30130d36116067e5
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/103340
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2019-05-21 19:40:17 +00:00
Konstantin Shcheglov cfdcfe2bfe Update DeclarationsTracker when a context options change.
E.g. when .packages changes, we want to re-scan the context for new
available libraries. We also don't want to discard all context, and
resend everything.

R=brianwilkerson@google.com

Bug: https://github.com/Dart-Code/Dart-Code/issues/1723
Change-Id: I19ee71c1d021fb9bcda9d02d86b7cbb078704aa7
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/103320
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2019-05-21 18:43:36 +00:00
Mike Fairhurst 2b6b0e00d9 Fix resolveToBound for nullability
Change-Id: I510c349251588356677d52574f259706ec2047e0
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/103183
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Mike Fairhurst <mfairhurst@google.com>
2019-05-21 17:58:56 +00:00
Brian Wilkerson 7c7738a9c7 Proposed AST interface for extension methods
Change-Id: I7c85a642eeaa862ecf9c6837c0a488938e8d97e9
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/101225
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Mike Fairhurst <mfairhurst@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Dan Rubel <danrubel@google.com>
Reviewed-by: Paul Berry <paulberry@google.com>
2019-05-21 17:16:38 +00:00
Konstantin Shcheglov 59381cd8d0 Fix summary2 linking when using API summaries, which don't include line starts.
R=brianwilkerson@google.com, paulberry@google.com

Change-Id: Iee403b154e4ca546ee69ae7cf0a8764d48ac7d34
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/103081
Reviewed-by: Paul Berry <paulberry@google.com>
2019-05-20 16:58:12 +00:00
Konstantin Shcheglov 59bcb38db7 Report the missing library in LinkedElementFactory.
R=brianwilkerson@google.com, paulberry@google.com

Change-Id: I0e949f853f90f676f0184acd511ddde880d87a02
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/103082
Reviewed-by: Paul Berry <paulberry@google.com>
2019-05-20 16:57:56 +00:00
Konstantin Shcheglov e13b1b6e0c Build summary2 for SDK.
Note, that this will start building it always, regardless of the
state of the useSummary2 flag.

Summary1: 4892680 bytes.
Summary2: 7105744 bytes.
Both:    10748992 bytes.

Time:
Summary1: 2550 ms.
Summary2: 2750 ms.
Both:     4000 ms.

Change-Id: If81367c24654c1d57a4dcdbd42f76d80ae8c4b39
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/102540
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2019-05-19 20:05:01 +00:00
Konstantin Shcheglov 58cf83df4d Don't crash on during indexing references to named parameters of a generic function types.
R=brianwilkerson@google.com

Change-Id: I0da0b1785d7dab2c7c84527317e542b7ef718bd3
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/103080
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2019-05-19 19:08:31 +00:00
Konstantin Shcheglov 5e5b03881c Fix for exporting setters.
R=brianwilkerson@google.com

Change-Id: Ie67834547a94a480e8ed86df430c40bcb36e37e1
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/103024
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2019-05-19 17:50:09 +00:00
Konstantin Shcheglov 234103f9d4 Fix for hasImplicitReturnType.
R=brianwilkerson@google.com

Change-Id: I94e1e0f8246f3ff0d284ef7b1de6f618ad464592
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/102984
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2019-05-19 17:50:07 +00:00
Paul Berry f930d674ca Restore old nullability behavior of TypeParameterElement.type.
It doesn't work to make TypeParameterElement.type choose
nullability/non-nullability based on the enclosing library, because
for type parameters of synthetic function types, there is no enclosing
library.

Change-Id: Ic74cc639534e3c03f3c46e7eacfb5655ca74019a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/102981
Auto-Submit: Paul Berry <paulberry@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2019-05-18 15:05:26 +00:00
Brian Wilkerson ce62987c9d Remove DynamicState and make NumState an abstract class
Change-Id: I6c3ec94a26f6522d24cf964823b739dfe2c42c62
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/103021
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2019-05-18 14:18:46 +00:00
Konstantin Shcheglov 9b1c8fca91 More fixes for GenericFunctionType.
1. Read GenericFunctionType fully, but in two steps to avoid recursion.
   We need to read it fully, because it might be a part of a const
   initializer, so the client might request the initializer expression,
   and there is no way to him to finish reading. Amnd in general, we
   don't read expressions lazily.

2. For consistency we need to set identifiers for all GenericFunctionType
   nodes that we want to store. So, DeclarationResolver should be updated
   to move the identifier number even though we don't use the same
   mechanism for building elements ininitializers, as we use for type
   annotations outside expressions.

R=brianwilkerson@google.com

Change-Id: I58faa5408bff5250a8c775249438def7f742594b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/102840
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2019-05-18 00:20:36 +00:00
Konstantin Shcheglov cf15dc17e0 With summary2 FunctionTypedFormalParameter has type parameters.
This re-applies changes to tests from https://dart-review.googlesource.com/c/sdk/+/100620

R=brianwilkerson@google.com

Change-Id: If6721d2febb39b52277fdb39845bb2486cb6eb47
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/102860
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2019-05-17 23:31:16 +00:00
danrubel 7983fac33b add "extension" built-in keyword for extension methods
Change-Id: I6529fff31f681fd24c22f8c7579d2a35097f4d07
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/102940
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Dan Rubel <danrubel@google.com>
2019-05-17 22:24:15 +00:00
Paul Berry 8d52c0d08e Store library nullability status in LibraryElement; adjust TypeParameterElement.type based on it.
Change-Id: I0a9673b3b2f46bbf5c3aea429e90c6ddafa978e4
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/102224
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Paul Berry <paulberry@google.com>
2019-05-17 21:27:21 +00:00
danrubel b4611b9357 add extension-methods experimental feature
Change-Id: Iad76a6d0b91ff83fce3dbd963d0c341b3b62eeb9
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/102880
Reviewed-by: Paul Berry <paulberry@google.com>
Commit-Queue: Dan Rubel <danrubel@google.com>
2019-05-17 13:15:30 +00:00
Paul Berry 1c469617c5 TypeParameter.declaredElement is guaranteed to be a TypeParameterElement
Change-Id: Ia6af1109cce334362885e1db150608f38081f064
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/102600
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Paul Berry <paulberry@google.com>
2019-05-15 15:59:24 +00:00
pq af2d02f9c8 fix lint code reporting
Fixes: https://github.com/dart-lang/linter/issues/1568

Change-Id: I38d6138aa76fd79c11ef4d603705fdf2e29541e9
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/102581
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Phil Quitslund <pquitslund@google.com>
2019-05-15 15:36:39 +00:00
Konstantin Shcheglov f6d3466856 Work around DDC with summary2 for now.
We will need to patch DDC to link summary2, but for now it uses
sumamry1, and I'd like to build SDK and run analyzer tests on bots.

R=brianwilkerson@google.com

Change-Id: I7ac74b87a4bce1a1e08925256dc1edfc55406f3e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/102503
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2019-05-15 13:36:19 +00:00
Konstantin Shcheglov 6ac6d3ae7d Fix FileState refresh2 to allow caching.
R=brianwilkerson@google.com

Change-Id: I1654809d90ae24f41a42f9130266493f27525003
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/102320
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2019-05-15 01:57:17 +00:00
Mike Fairhurst a3073fc581 check null condition in assert
Change-Id: I4de11a7de3e5106ce9d5fbaf89d0b0965d637b08
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/102221
Auto-Submit: Mike Fairhurst <mfairhurst@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Mike Fairhurst <mfairhurst@google.com>
2019-05-14 22:24:34 +00:00
Konstantin Shcheglov ebaf0ad8b1 Record GenericFunctionType nodes separately in the unit.
This fixes most failures related to them.

R=brianwilkerson@google.com, paulberry@google.com

Change-Id: Icbd9eac52159064d5ffc43a4b30b75589a089a94
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/102480
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2019-05-14 21:32:33 +00:00
Dan Rubel c855b9bfa3 move error token processing to parser
Change-Id: Ic886db54e68206d7ddc9f68bacaaecf9f86aafc0
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/102461
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Dan Rubel <danrubel@google.com>
2019-05-14 15:49:33 +00:00
danrubel a50dcd8fe6 remove unused field
Change-Id: Id789870f4e4be6189356a1cd25ed06f397e9d0f8
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/102462
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
Auto-Submit: Dan Rubel <danrubel@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
2019-05-14 13:00:46 +00:00
Paul Berry 27df933bd1 Fix some hints in the analyzer package.
Change-Id: I46dd91ef2a78dffc08f2fdb45d9646a966a3315d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/102380
Auto-Submit: Paul Berry <paulberry@google.com>
Reviewed-by: Samuel Rawlins <srawlins@google.com>
Commit-Queue: Paul Berry <paulberry@google.com>
2019-05-13 12:51:30 +00:00
Konstantin Shcheglov d0869386f6 More optimizations for summary2 storage format.
1. Unwrap ArgumentList and TypeArgumentList.

2. Don't even try to write and read tokens.

Performance difference does not look significant, but we are now
talking about something like 5% or 10% difference with summary1, so
probably any improvement matters.

R=brianwilkerson@google.com

Change-Id: I5bdd090e1897cfdf596a99af8a198d0078fc7d18
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/102280
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2019-05-12 22:03:57 +00:00
Konstantin Shcheglov ca92a30299 Reuse LibraryScope in MetadataResolver.
R=brianwilkerson@google.com

Change-Id: If8ef8003fa800924facb5e59a99e1b7885a94093
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/102281
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2019-05-12 17:24:57 +00:00
Konstantin Shcheglov 42c35d7bd6 Optimize summary2.
1. Don't store tokens.
2. Start moving toward storing only semantic information.
3. Don't use DeclarationSplicer, DeclarationResolver.
4. GenericFunctionType(s) don't work, we need a way to associate AST
location to summary location. I think it is solvable.

Change-Id: If0bf9f20f8092068488322129853b788dd947eb0
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/102127
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2019-05-11 15:49:39 +00:00
Mike Fairhurst b91a4f5423 [analyzer] Resolve methodName staticType when Function to check Function?
Change-Id: I85d43821d4b792c269f386616dcc21d144772c5e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/102201
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Mike Fairhurst <mfairhurst@google.com>
2019-05-10 21:45:29 +00:00
Paul Berry 11b59bec8d Store compilation unit NNBD status in unlinked summary.
This is needed for two reasons:

1. Summary linking, because type inference needs to behave differently
for opted-in vs. opted-out libraries.

2. Summary resynthesis, because TypeParameterElement.type needs to
behave differently for opted-in vs. opted-out libraries.

Note that reason 1 won't apply to the summary2 mechanism, because it
has access to full ASTs when doing type inference.  But it will still
need to record compilation unit NNBD status for reason 2.

This CL merely stores the correct data in the summary; it doesn't
address resynthesis, linking, or summary2.

Change-Id: I1aa2226e5865ef76747267de6198223997d6ad0d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/101920
Commit-Queue: Paul Berry <paulberry@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
2019-05-10 21:34:08 +00:00
Sam Rawlins dac5a56422 Fix workspace/package identification for package:build packages
Fixes https://github.com/dart-lang/linter/issues/1393

Change-Id: I064faad8da50bc1a6c8a80a0412f792914915f8e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/102200
Commit-Queue: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2019-05-10 21:31:18 +00:00
Paul Berry 370b393ac5 Remove redundant optimization from callers of withNullability.
Change-Id: I9b9ccd3b5c85499ac2667e864374a86b5ff1c2f9
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/102000
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Paul Berry <paulberry@google.com>
2019-05-10 21:12:48 +00:00
Brian Wilkerson 5cffcd9e2c Add the class NonNullableTypeProvider to access SDK classes in opted-in context
Change-Id: Id0cd7c8cd6f93701a5e603753b10a27236292d41
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/102202
Reviewed-by: Mike Fairhurst <mfairhurst@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2019-05-10 18:51:38 +00:00
Brian Wilkerson 36d8e3a9ba Fix more places where hardcoded types need to be made non-nullable under NNBD
Change-Id: I16dbabecdef743b291a4ae85414e95ffa533d723
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/102060
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2019-05-10 17:52:47 +00:00
Paul Berry 63001295c0 optionally report scanner errors before parsing
The fasta parser handles error tokens produced by the scanner
but the old parser expect error tokens to have been already
translated into error messages. This updates the analyzer scanner
to optionally translate scanner errors.

Change-Id: I62383965285511c93e8fbf6a4cada97e9e4e3c04
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/102143
Commit-Queue: Paul Berry <paulberry@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2019-05-10 17:49:57 +00:00
Konstantin Shcheglov 2c86872a5f Store isAsynchronous and isGenerator in executables.
So, that we don't have to read bodies to know if these executables
are async / generators.

R=brianwilkerson@google.com

Change-Id: I1a88f896a9d1b0539a021b1f12b7b55ac44ca44a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/102100
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2019-05-09 23:32:11 +00:00
Konstantin Shcheglov 4a058a3773 Check for hasDefaultValue / hasInitializer directly, without reding the initializer.
R=brianwilkerson@google.com

Change-Id: I29b37bc2305bf044d8a5b28b78edeba4cab9c120
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/102102
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2019-05-09 23:32:05 +00:00
Mike Fairhurst 536ecbac7b Add language 2 tests for null access errors
Change-Id: Icde35448c183a3b9311811aab388909d17e36ceb
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/101461
Commit-Queue: Mike Fairhurst <mfairhurst@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2019-05-09 18:59:11 +00:00
Brian Wilkerson 130ad1bcf9 Stop reporting some errors when constant evaluation produces a valid object with an unknown state (issue 36873)
Change-Id: I1bf9c0aebaee24ab0c9e2b40c9881d478e33f87c
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/102001
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2019-05-09 18:45:01 +00:00
Brian Wilkerson d1a5eb5900 Fix the special casing of binary operators with primitive types when NNBD is enabled
Change-Id: I36f7f63b26eb3ea87efbe7af96d2134ea6402158
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/102020
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2019-05-09 18:44:12 +00:00
danrubel b4e2c0246c update parser to handle leading error tokens
This is the first of several CLs that move error tokens to the head
of the token stream so that parser handling of error tokens
can be simplified and less error prone.

In this particular CL:
- update parser to handle error tokens at the head of the token stream
- remove several places that analyzer was preprocessing error tokens
   now that the parser handles them

Change-Id: Iddf60ab2879567a345a692b64043bd42f1871947
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/102040
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Dan Rubel <danrubel@google.com>
2019-05-09 18:36:31 +00:00
Paul Berry 1407e59079 Add preliminary NNBD support to the summary linker.
Change-Id: I256d66333d9715ed720bd6ea87d21fd00e17635a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/101900
Commit-Queue: Paul Berry <paulberry@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2019-05-08 22:35:49 +00:00