Commit Graph

4276 Commits

Author SHA1 Message Date
Brian Wilkerson 2dd6aba0f4 Add the analyzer implementation of Forest
Change-Id: I1b88b0b38090d0b3e98085944fb014ce29441810
Reviewed-on: https://dart-review.googlesource.com/54061
Reviewed-by: Dan Rubel <danrubel@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2018-05-07 19:14:02 +00:00
Paul Berry 07ad1904f3 Sort declarations in type_system.dart and type_system_test.dart.
No changes other than moving around classes and methods.

Change-Id: I2bca30b7bd3bba85d0cbeb2ac2e2fe975aa3db62
Reviewed-on: https://dart-review.googlesource.com/53821
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Paul Berry <paulberry@google.com>
2018-05-04 18:46:56 +00:00
Konstantin Shcheglov b7a63c8d52 Use @isTest and @isTestGroup to understand executable element as a test/group.
R=brianwilkerson@google.com, devoncarew@google.com

Bug: https://github.com/flutter/flutter-intellij/issues/2055
Change-Id: I7c8e7639d111eca63df0780ebdec182573493047
Reviewed-on: https://dart-review.googlesource.com/53690
Reviewed-by: Devon Carew <devoncarew@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2018-05-04 17:09:06 +00:00
Paul Berry 8f52be2282 Don't infer types when there's an irreconcilable type mismatch.
Also fix the type inference algorithm so that when it explores
multiple alternatives (as a result of the use of FutureOr<>), if one
alternative generated some constraints but failed to produce a match,
it rewinds those constraints and tries the other alternative.
(Previously, it erroneously assumed that if any constraints were
generated, the alternative matched successfully).

Also add unit tests to verify the proper operation of the subtype
match algorithm.

Fixes #32305.

Change-Id: I060b5d6d5247a68d2b27bba78819bae172e43d97
Reviewed-on: https://dart-review.googlesource.com/53685
Commit-Queue: Paul Berry <paulberry@google.com>
Reviewed-by: Jenny Messerly <jmesserly@google.com>
2018-05-03 23:27:14 +00:00
Konstantin Shcheglov dfa661d460 Add AnalysisSessionHelper.getTopLevelPropertyAccessor().
R=paulberry@google.com

Change-Id: I37c172ff087e1f4a6a859abb1304d18aedd34dfe
Reviewed-on: https://dart-review.googlesource.com/53686
Reviewed-by: Paul Berry <paulberry@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2018-05-03 21:51:14 +00:00
Konstantin Shcheglov fd27cc3435 Don't store bytes in the file cache.
We needed bytes only to get their length.
This CL replaces it to using the content (String) length.
This should help to fix heap usage regression.

R=paulberry@google.com

Change-Id: I4d58e91987db21233a71ca600eea8fae3fb38346
Reviewed-on: https://dart-review.googlesource.com/53243
Reviewed-by: Paul Berry <paulberry@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2018-05-01 21:11:04 +00:00
Leaf Petersen 0b8734acb2 Fix some erroneous errors associated with returns in void functions.
Fixes https://github.com/dart-lang/sdk/issues/32443 .

A separate CL with language tests for a super set of the errors covered by this CL is in progress.

Change-Id: I1a0f6a6a347f75b8e332c8bfccf8fbbd32f20efe
Reviewed-on: https://dart-review.googlesource.com/52980
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2018-04-27 22:08:09 +00:00
Konstantin Shcheglov e44bc903e0 Remove UnitLintRule.
R=brianwilkerson@google.com

Change-Id: Ib89333a6afc6a4785eff47ee3433c9e0dc8a5a40
Reviewed-on: https://dart-review.googlesource.com/52883
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2018-04-27 17:51:26 +00:00
Konstantin Shcheglov 70547d8197 Change linter subscriptions from functions to AstVisitor(s).
The performance I see is similar to using functions.

R=brianwilkerson@google.com

Change-Id: Ib5f675f07b422bd9e6f28df0f9d7ea8b24669f63
Reviewed-on: https://dart-review.googlesource.com/52881
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2018-04-27 16:51:47 +00:00
Brian Wilkerson 1c5d1a56e7 Clean up some hints
Change-Id: I623a4d86912ad0666b75ad519c15c84b24a5b579
Reviewed-on: https://dart-review.googlesource.com/52861
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
2018-04-26 22:29:06 +00:00
Brian Wilkerson cb15b43c32 Add support for getting parse results synchronously
Change-Id: I2a6c4507fcc6debf3d4ffc3458621100d184619b
Reviewed-on: https://dart-review.googlesource.com/52820
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
2018-04-26 20:24:46 +00:00
Konstantin Shcheglov c97d36c127 Add all concrete AST nodes for lints to subscribe.
R=brianwilkerson@google.com, pquitslund@google.com

Change-Id: Idb21390d49e5963f28c14db8d3ae27e77287e7c3
Reviewed-on: https://dart-review.googlesource.com/52741
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2018-04-26 18:19:21 +00:00
Janice Collins 1afe71c08a Enable preview-dart-2 as default for analyzer.
Based on https://dart-review.googlesource.com/c/sdk/+/52340, but adds
the necessary plumbing through the test system to pass through
negations to strong and preview-dart-2.  Also adds support for those
negations to the analyzer.

Change-Id: I9793ff28bb593d25bbb0a2ed8736b5b53e0a62d8
Reviewed-on: https://dart-review.googlesource.com/52461
Commit-Queue: Janice Collins <jcollins@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2018-04-26 17:01:12 +00:00
Konstantin Shcheglov 1030189d56 Add NodeLintRule and UnitLintRule that replace AstVisitor in lints.
This makes the Flutter repo analysis about 6% faster.

Before: 56.9 57.4 56.9 57.3 56.5 56.9 56.6
After:  53.5 53.0 53.8 54.3 53.5 53.0 53.0

To see the different better, I ran lints 100 and 10 times for each file.
Before: 628 621 109 107 109
After:  338 333  77  75  76

To get these numbers we will need to make corresponding changes to lints,
to implement these interfaces, so that they are used instead or the
current visitors. I have these changes locally, but we would need to
publish analyzer first.

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

Change-Id: I8b4efe05f815082fe39c33c303bb92b7dac19f65
Reviewed-on: https://dart-review.googlesource.com/52644
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Phil Quitslund <pquitslund@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2018-04-25 21:22:42 +00:00
Brian Wilkerson 9e9b50d19d Improve error messages for annotations involving undefined names (issue 27788)
Change-Id: Iccfcb73b7671f50353b57a81817dec013b997a53
Reviewed-on: https://dart-review.googlesource.com/52640
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2018-04-25 17:48:49 +00:00
danrubel 34a1ba7307 Fix AstBuilder construction of if statement
... and update more analyzer tests

Change-Id: Ieed123e16e7ae451cf2046253deb0c7773091417
Reviewed-on: https://dart-review.googlesource.com/52500
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Dan Rubel <danrubel@google.com>
2018-04-24 22:00:38 +00:00
Paul Berry dc21d3ce9d Export SyntheticBeginToken and SyntheticToken from the analyzer.
These classes are needed by the angular_analyzer_plugin project, and
we don't want to make it depend directly on front_end, so we need to
re-export the classes from the analyzer.  See discussion at
https://github.com/dart-lang/angular_analyzer_plugin/pull/558#discussion_r183825214

Change-Id: Ide0264e3e04f783eb9f68079cc2de8a6acfb94b3
Reviewed-on: https://dart-review.googlesource.com/52425
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Paul Berry <paulberry@google.com>
2018-04-24 21:44:08 +00:00
Brian Wilkerson 7054d92a02 Remove some classes from the analyzer public API
Change-Id: Ic53a8426818b06f44c2876abd16c789589bf78b5
Reviewed-on: https://dart-review.googlesource.com/52421
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2018-04-24 15:28:15 +00:00
Aske Simon Christensen 9c2fcedaf4 Error on missing method implementation in non-abstract class
Bug: https://github.com/dart-lang/sdk/issues/32013

Change-Id: I163a84e70e94852a05ce99b07ec883c610ea788c
Reviewed-on: https://dart-review.googlesource.com/52320
Commit-Queue: Aske Simon Christensen <askesc@google.com>
Reviewed-by: Dmitry Stefantsov <dmitryas@google.com>
2018-04-24 13:07:54 +00:00
Brian Wilkerson bf1d0efde2 Revert "Improve error messages for annotations involving undefined names (issue 27788)"
Change-Id: I017592bf8982ff51bb73eb5fe892f8d9cffb9c9d
Reviewed-on: https://dart-review.googlesource.com/52400
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2018-04-23 21:05:53 +00:00
Brian Wilkerson 1ffd7e529a Improve error messages for annotations involving undefined names (issue 27788)
Change-Id: Ib7af4bdd97e9f775646c90e8f49f021836125b78
Reviewed-on: https://dart-review.googlesource.com/52240
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
2018-04-22 20:11:11 +00:00
Konstantin Shcheglov 6865041334 Issue 27098. Check that argument is assignable to parameter in call().
R=brianwilkerson@google.com

Bug: https://github.com/dart-lang/sdk/issues/27098
Change-Id: I0d5ac65202b632646bd7b26170c55ab985d2523c
Reviewed-on: https://dart-review.googlesource.com/52263
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2018-04-20 21:50:59 +00:00
Konstantin Shcheglov 818c4b5bfd Remove AbsolutePathContext and use package:path instead.
I see however that linter/test/rule_test.dart uses it, but as far as I
can see, that's it. All other usages are from analyzer and
analysis_server.

R=brianwilkerson@google.com

Change-Id: I2b82870a4a4ec6f155326d8ee6dc1c1028f84793
Reviewed-on: https://dart-review.googlesource.com/52265
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2018-04-20 21:01:06 +00:00
Mike Fairhurst bd757f9948 Redo #28580: instantiate bounds to bounds.
One thing to be careful of here is that function type bounds may be
left unbounded. However, their parameters and return type cannot refer
to a type parameter for resolve-to-bounds to work.

There are also a large number of ways that this can loop infinitely, and
a number of new guards had to be added (as well as some test cases) to
catch them all.

Change-Id: I14322f5f71d1f7b73b27a870553e5c588b2c7e2e
Reviewed-on: https://dart-review.googlesource.com/52062
Commit-Queue: Mike Fairhurst <mfairhurst@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
2018-04-20 17:25:09 +00:00
danrubel 10b441b16b Improve conditional import expression recovery
This improves recovery when parsing conditional import expressions
by repositioning the synthetic closing ')' that was inserted by the
scanner in a less than optimal location.

This approach relies on the beforeSynthetic field being set correctly.
While the scanner still sets the 'next' and 'beforeSynthetic' fields
directly for efficiency, most other functions which update an existing
token stream have been revised to call 'setNext()' rather than setting
the 'next' field directly. This ensures that the 'beforeSynthetic' field
will be correctly updated.

Change-Id: Id631fd600c64d1feaf00593acb74a7070e354f07
Reviewed-on: https://dart-review.googlesource.com/52120
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Dan Rubel <danrubel@google.com>
2018-04-20 13:58:50 +00:00
Brian Wilkerson 1a56d6534c Add a recovery test based on reported failure (and fix a minor bug)
Change-Id: Ieaa0309559f7b2cc5c24741f16194c98f9ba0df2
Reviewed-on: https://dart-review.googlesource.com/51960
Reviewed-by: Dan Rubel <danrubel@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2018-04-19 18:47:19 +00:00
Aske Simon Christensen 2b09c1efc0 Revert "Error on missing method implementation in non-abstract class"
This reverts commit 7cc55d0372.

Reason for revert: More test fixes needed.

Change-Id: Ib36159184ffbd14ce3f7cca184ce2b8cdfec237c
Reviewed-on: https://dart-review.googlesource.com/51680
Reviewed-by: Aske Simon Christensen <askesc@google.com>
Commit-Queue: Aske Simon Christensen <askesc@google.com>
2018-04-18 17:27:22 +00:00
Aske Simon Christensen 7cc55d0372 Error on missing method implementation in non-abstract class
Closes https://github.com/dart-lang/sdk/issues/32013

Change-Id: I8f49d2640ef92a3d9d723969208cdb5f397e806d
Reviewed-on: https://dart-review.googlesource.com/43660
Commit-Queue: Aske Simon Christensen <askesc@google.com>
Reviewed-by: Peter von der Ahé <ahe@google.com>
2018-04-18 14:39:09 +00:00
danrubel 17d7f23e71 Improve fasta parser conditional import recovery
Change-Id: I5479078d8d2c3de10b74ed04001fdd852a427c5c
Reviewed-on: https://dart-review.googlesource.com/51561
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Dan Rubel <danrubel@google.com>
2018-04-18 11:04:19 +00:00
Konstantin Shcheglov 5990a51456 Optimize computing exported namespaces in prelinker.
Similar to https://dart-review.googlesource.com/51442, we compute
export namespaces recursively and remember full export namespaces
when there are no cycles.

This makes Flutter analysis about 8% faster.

Before: 59.8 60.0 59.4
After:  55.2 55.3 55.1 55.6 55.4

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

Change-Id: Id78aae1ff475e4386e5a01a01b92f0768a0cd4aa
Reviewed-on: https://dart-review.googlesource.com/51582
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2018-04-18 01:11:28 +00:00
Dan Rubel 8e812ddaa5 Pass modifiers in beginFormalParameters event
This CL updates the beginFormalParameters event to include
the covariant and const/final/var modifiers, and cleans up
a number of unused classes and methods including:

* the original implementation of ModifierContext/Recovery
* handleModifier and handleModifiers events

Change-Id: Ie89a202d17872fba85cd1a477091472a8d2d223b
Reviewed-on: https://dart-review.googlesource.com/51380
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Dan Rubel <danrubel@google.com>
2018-04-17 20:27:37 +00:00
Brian Wilkerson b936ffb329 Move several libraries out of the public API
Change-Id: I8259de00134310f25b1c6168940aea5190488999
Reviewed-on: https://dart-review.googlesource.com/51443
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
2018-04-17 17:35:27 +00:00
Konstantin Shcheglov fcb4c671b0 Optimize computing exported namespaces in FileState.
Instead of chasing exports in each FileState library individually, we
perform recursive computation, and remember computed export namespaces
for visited branches. Cycles require special handling - we don't
remember partial namespaces, we compute one full export namespace and
so break the cycle; then the rest also can be computed in one pass.

This makes Analysis Server a bit faster for some Quick Fixes, and
what is more important, is a playground to test the idea of makeing
the similar change to _Prelinker. We spend 8% of total analysis time
chasing long chains of exports in Flutter.

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

Change-Id: Ia45cff9a7fb24aac2e72fe50752274b764462017
Reviewed-on: https://dart-review.googlesource.com/51442
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2018-04-17 04:45:58 +00:00
Brian Wilkerson 5460ddbab5 Move three more libraries out of the public API
Change-Id: I8e6aeaea35c739fb26e22ffcfc30a343ebbb5424
Reviewed-on: https://dart-review.googlesource.com/51363
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2018-04-16 22:15:28 +00:00
Devon Carew 9968728df1 Remove package:cli_util deps from package:analyzer.
Change-Id: I6bda63e31b9a8eb3e7ede406bd7e3e5748130ff6
Reviewed-on: https://dart-review.googlesource.com/51362
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Devon Carew <devoncarew@google.com>
2018-04-16 20:26:08 +00:00
danrubel 0ca8b6e5be Improve recovery when "assert" is used in an expression
Change-Id: I01e8c6fbe0faf6ce6ded32b2cfa1ec034f22588d
Reviewed-on: https://dart-review.googlesource.com/51341
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Dan Rubel <danrubel@google.com>
2018-04-16 20:20:49 +00:00
Brian Wilkerson d4a1896cfb Demote IMPORT_DUPLICATED_LIBRARY_NAMED to a warning
Change-Id: I2655446e333096f4c7f54a25e7659f9446a62bbf
Reviewed-on: https://dart-review.googlesource.com/50320
Reviewed-by: Vijay Menon <vsm@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2018-04-16 20:06:38 +00:00
Konstantin Shcheglov 35fecb4a10 Issue 32896. Add isXYZ accessors to ParameterElementForLink_VariableSetter.
R=brianwilkerson@google.com

Bug: https://github.com/dart-lang/sdk/issues/32896
Change-Id: I2482912b9d18c7bdb9d08b0ffd06fbf4699427a3
Reviewed-on: https://dart-review.googlesource.com/51243
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2018-04-16 18:26:13 +00:00
Brian Wilkerson dd897d35a2 Move the task API out of the public API
Change-Id: I0fbafb4965ced89fb9a063edb773c3f1cb3a39fa
Reviewed-on: https://dart-review.googlesource.com/51242
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
2018-04-16 18:18:08 +00:00
Brian Wilkerson 805c08d8bf Fix a run-time type issue when running in Dart 2 mode
Change-Id: Ic612510dbdc893c86a8b66afd12fe044cbf50f02
Reviewed-on: https://dart-review.googlesource.com/51204
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2018-04-13 22:17:51 +00:00
Konstantin Shcheglov 6fe7a86e7f Replace SourceFactory.resolveUri() with resolveRelativeUri() in resynthesizer.
This makes Flutter repository analysis another 10% faster.

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

Before: 65.6 66.0 67.2 67.1
After:  60.7 60.3 59.7 61.1
Change-Id: Ie0282f9480c2553b549f9636edbab8a59df32e3f
Reviewed-on: https://dart-review.googlesource.com/51160
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Devon Carew <devoncarew@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2018-04-13 17:55:05 +00:00
Leaf Petersen c2b338f1b7 Remove fuzzy arrow support from analyzer
Fixes #31637

Change-Id: I87767b92814455187ea71cc4caca786043dbbe3d
Reviewed-on: https://dart-review.googlesource.com/51100
Commit-Queue: Leaf Petersen <leafp@google.com>
Reviewed-by: Jenny Messerly <jmesserly@google.com>
2018-04-13 16:47:16 +00:00
Konstantin Shcheglov 9976cddcd7 Shared cache of FileState contents.
This makes Flutter repo analysis about 12% faster.

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

Base: 76.2 74.9 75.9
After: 65.6 66.0 66.6 67.1
Change-Id: I5afffdae15eacf2c09c4ede40d7312c8827bae0c
Reviewed-on: https://dart-review.googlesource.com/51061
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Devon Carew <devoncarew@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2018-04-13 16:43:36 +00:00
Brian Wilkerson c214c43758 Make LineInfo a public class
Change-Id: I1bc7f5302797374609752ea5293b96c30719b41f
Reviewed-on: https://dart-review.googlesource.com/51101
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2018-04-13 16:23:47 +00:00
Ian McKellar 92f1d0fab4 [gn] Allow single or double quotes in .config
Change-Id: I1b80d14d2f89c8f652005313860e9003f6856a9a
Reviewed-on: https://dart-review.googlesource.com/51001
Reviewed-by: Ryan Macnak <rmacnak@google.com>
Commit-Queue: Ryan Macnak <rmacnak@google.com>
2018-04-12 23:07:56 +00:00
Brian Wilkerson 5e1cb4d41b Make SourceRange part of analyzers public API
Change-Id: I06376814ab2992623fed6d3121baa861522186c9
Reviewed-on: https://dart-review.googlesource.com/51046
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2018-04-12 21:13:16 +00:00
Konstantin Shcheglov 6d7df88fa3 Delay computing file name sets until they are requested.
This makes Flutter repo analysis about 1 second faster.

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

Before: 74.8 74.8 73.3 72.7
After:  72.3 72.2 72.2 72.6
Change-Id: Iedc6a3d25a4de051b9207fbb6e549e7f3575a75a
Reviewed-on: https://dart-review.googlesource.com/51020
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2018-04-12 19:36:09 +00:00
Brian Wilkerson 16a4ed7dc4 Remove an unused subclass of LineInfo
Change-Id: I9503b52de9ed43c94432dd9c6b36719c4192d610
Reviewed-on: https://dart-review.googlesource.com/50960
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
2018-04-12 16:26:59 +00:00
Jenny Messerly a9c3dabb4c fix #32769, performance regression in Analyzer callable function support
isAssignableTo should check for subtype first, and it should only check
for a call method if the other side accepts a function type.

Also improves performance of the recursive guard checking: function
types should not need it (pruning takes care of that), so we can simplify
the code for interface types. Also adds TODO comments for some bugs I
found while reading the _matchSubtype code.

Change-Id: I7b3318e3cc1f89c09960efe82d3cfdbf48ab9746
Reviewed-on: https://dart-review.googlesource.com/49962
Commit-Queue: Jenny Messerly <jmesserly@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Leaf Petersen <leafp@google.com>
2018-04-11 22:59:09 +00:00
danrubel 072bd1c88e Remove KernelLibraryBuilder proxies
Change-Id: Ib2326bc4700e5063c2885664389a5310d672fbea
Reviewed-on: https://dart-review.googlesource.com/50780
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Dan Rubel <danrubel@google.com>
2018-04-11 18:12:36 +00:00