Konstantin Shcheglov
2622d728ae
Add getLibraryByUri2(), deprecate getLibraryByUri().
...
R=brianwilkerson@google.com
Change-Id: I6769ccb5767408490934693cc9019d5af1d8d8d9
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/195763
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2021-04-19 00:19:32 +00:00
Konstantin Shcheglov
4dc165f7fd
Add getUnitElement2(), deprecate getUnitElement().
...
Change-Id: Ib1ed93f215356442ca9db5b8ed5fab99667e996e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/195361
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2021-04-15 17:16:27 +00:00
Konstantin Shcheglov
1469f984fc
Migrate lib/src/services/search/
...
Change-Id: I52b2fb72952c0abacb897607d6969bedbfd027b0
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/194114
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2021-04-06 22:58:25 +00:00
Konstantin Shcheglov
e97f1bdbf0
Switch analysis_server to language 2.12, so null safety, but opt-out files.
...
This should allow doing partial migration, specifically protocol files,
which are imported by other libraries, but are a small library cycle
that does not import much outside of it.
Change-Id: I904c05d6d5b444ee9a9dbd1f7ada12aabdcc5165
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/193583
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2021-03-30 23:39:37 +00:00
Konstantin Shcheglov
cfe510ade8
Test for search of non-function type alias.
...
Change-Id: Iab2fc3980563a321eec3cf4e843d487b7b2b399d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/179320
Reviewed-by: Samuel Rawlins <srawlins@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2021-01-14 21:52:13 +00:00
Konstantin Shcheglov
ea775a6a0f
Migrate SearchEngineImplTest to AnalysisContextCollection.
...
Change-Id: Ide259d4baf2a309a08ae74019ecb95d54d97f365
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/177440
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2021-01-02 19:21:16 +00:00
Mike Fairhurst
1134a0f17c
[analysis_server] Remove unused dart:async imports
...
Change-Id: I764ee78cb9e31bdb3abaa36ca4754e1fed180311
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/161447
Auto-Submit: Mike Fairhurst <mfairhurst@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
2020-09-02 17:29:52 +00:00
Brian Wilkerson
8969b1839c
Enable omit_local_variable_types in analysis_server
...
Change-Id: I7e5c13d40fd276854601681fc84be321e6031b10
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/141583
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2020-03-30 03:58:44 +00:00
Konstantin Shcheglov
abf7d1fc08
Issue 40572. Pass Packages to AnalysisDriver.
...
Just as SourceFactory is given to AnalysisDriver, so should be Packages.
Understanding --packages and discovery in out of scope.
Bug: https://github.com/dart-lang/sdk/issues/40572
Change-Id: Id120fba0f23a4423797fa9976c4cda5ed54dad53
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/135188
Reviewed-by: Paul Berry <paulberry@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-02-11 00:57:45 +00:00
Brian Wilkerson
58a9c22f80
Add return types to more methods in analysis_server
...
Change-Id: I65bed353bcff4f991faf8c3bdde979789a8d962b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/134000
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2020-01-30 21:43:34 +00:00
Brian Wilkerson
4043a6fce3
Remove unnecessary uses of new in analysis_server
...
Other than analysis_options.yaml, all of the changes were from running
dartfix.
Change-Id: I92411642f12a00fc6bd0bfd24dd60fe67f0fed16
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/128845
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2019-12-18 19:01:51 +00:00
Konstantin Shcheglov
3389b3bd32
Remove Packages from SourceFactory.
...
We have PackageMapUriResolver, this should be the way to resolve
all `package:xyz` URIs. We should not repeat it in SourceFactory.
Change-Id: I52d33dbf7e2d44f2c53521f6a51b0aea70507d3e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/128106
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2019-12-12 17:10:00 +00:00
Brian Wilkerson
01e0df71a8
Stop unnecessarily extending Object
...
Change-Id: Ib557755916b09be4e1ad1b1c2e4bed052a280513
Reviewed-on: https://dart-review.googlesource.com/c/84640
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2018-11-16 16:43:24 +00:00
Konstantin Shcheglov
b71948faee
Consolidate MockSdk(s) into one, living in analyzer/lib/src/test_utilities.
...
R=brianwilkerson@google.com , paulberry@google.com
Change-Id: I70946b8e6f790608ad52c8f27cd6f506673f7b0d
Reviewed-on: https://dart-review.googlesource.com/c/82710
Reviewed-by: Paul Berry <paulberry@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2018-11-02 21:52:44 +00:00
Konstantin Shcheglov
7c80d22878
Make indexing in AnalysisDriver optional.
...
This makes my Flutter benchmark about 6% faster.
It will not affect performance of `flutter analyze`, because for now
Analysis Server always enables indexing and search. But we could make
this optional, for DAS clients that need only errors, but not search,
refactorings, etc.
R=brianwilkerson@google.com , paulberry@google.com
Change-Id: I4eafc37592a3bb18bd2c6ab84dc2515a4d42697b
Reviewed-on: https://dart-review.googlesource.com/c/80880
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2018-10-21 20:20:05 +00:00
Peter von der Ahé
2a6b566ca2
Move byte store to package:analyzer
...
Change-Id: I1fc41cc0b2e2848565a5411d0512a4ca086ab659
Reviewed-on: https://dart-review.googlesource.com/c/77761
Commit-Queue: Peter von der Ahé <ahe@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Reviewed-by: Jens Johansen <jensj@google.com >
Auto-Submit: Peter von der Ahé <ahe@google.com >
2018-10-04 09:15:54 +00:00
Peter von der Ahé
45cb0815bc
Move PerformanceLogger to package:analyzer
...
Change-Id: I89a60ae9ab639c7907a92976e1eb8007d0f4ee9b
Reviewed-on: https://dart-review.googlesource.com/c/77760
Commit-Queue: Peter von der Ahé <ahe@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Reviewed-by: Jens Johansen <jensj@google.com >
Auto-Submit: Peter von der Ahé <ahe@google.com >
2018-10-04 08:44:43 +00:00
Konstantin Shcheglov
7cf078c05d
Index and search for mixins.
...
R=brianwilkerson@google.com
Change-Id: I5399507dc5a9688ee5944f6554167a6b1e8692b6
Reviewed-on: https://dart-review.googlesource.com/72525
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2018-08-31 21:38:26 +00:00
Konstantin Shcheglov
1f52372bfa
Remove CFE integration from analyzer, analysis_server, and analyzer_cli.
...
AnalysisDriverResolutionTest is partially updated, about 30 failing
tests added. I will get back to it in a following CL, it is not
directly CFE integration, but updated understanding how we want to
resolve. For example we don't need types for non-expression identifiers.
Change-Id: I3daddbb6c66ffad7a726f3313a1199fd7387aa04
Reviewed-on: https://dart-review.googlesource.com/71883
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2018-08-29 13:46:45 +00:00
Konstantin Shcheglov
9ef53bde19
Store codeOffset/length code fields and top-level variables.
...
R=brianwilkerson@google.com , paulberry@google.com
Change-Id: I4590a38245039a4c60144feab039cf8d0db00677
Reviewed-on: https://dart-review.googlesource.com/71040
Reviewed-by: Paul Berry <paulberry@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2018-08-22 01:53:36 +00:00
Konstantin Shcheglov
fe0640e3b1
Refactor way of providing file info, set codeRange for units.
...
This fixes a lot of search/refactoring tests, about 200.
R=brianwilkerson@google.com
Change-Id: I6ce5f61a08b8effa73ffde3861ff68eadd1f4e04
Reviewed-on: https://dart-review.googlesource.com/69383
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2018-08-10 20:43:54 +00:00
Konstantin Shcheglov
eab492385c
Updates for passing / failing analysis_server tests.
...
R=brianwilkerson@google.com
Change-Id: Ica615414f567cf62bb631824f95d9ef45b8a777a
Reviewed-on: https://dart-review.googlesource.com/69003
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2018-08-08 20:47:25 +00:00
Brian Wilkerson
83aa463fac
Enable a few more server tests under CFE
...
Change-Id: I5f0bd750d3da7658f836e45f02da5ef157e752ff
Reviewed-on: https://dart-review.googlesource.com/68960
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
2018-08-08 17:13:28 +00:00
Brian Wilkerson
87f753dbd3
Replace some declarations of element with declaredElement
...
Change-Id: Idd62472b16cccaa98749a510197ec8d0f5053cb1
Reviewed-on: https://dart-review.googlesource.com/67820
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Reviewed-by: Paul Berry <paulberry@google.com >
2018-08-02 16:00:36 +00:00
Devon Carew
2dd33c2a6c
Have the package:analyzer strong mode option hard coded to on. Delete several spec mode only tests.
...
Change-Id: I5dffec68d9845fe75936d55100c03306b6eda363
Reviewed-on: https://dart-review.googlesource.com/64060
Commit-Queue: Devon Carew <devoncarew@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
2018-07-10 05:30:10 +00:00
Konstantin Shcheglov
85b4a799eb
Search references to elements and subtypes in all known (and discovered) files.
...
We discover classes in packages, so it should improve situation for Flutter.
We don't yet discover files in SDK per se (although I already see a lot
of subclasses), so might still miss some files, but all search bits are
in place, we just need to do discovery in SDK. Should be easy to do
in a day or two.
Also search for private and local elements probably still work only
for added files, again will get to it in a following CL.
https://github.com/flutter/flutter-intellij/issues/2296
https://github.com/flutter/flutter-intellij/issues/2258
https://github.com/dart-lang/sdk/issues/26762
https://github.com/dart-lang/sdk/issues/29112
R=brianwilkerson@google.com
Change-Id: Ib2b73b4cb31fd14b2514e70fbfe58735418e74d5
Reviewed-on: https://dart-review.googlesource.com/57760
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2018-06-01 14:47:43 +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
Brian Wilkerson
98e0c26a89
Convert several test classes to use ResourceProviderMixin
...
Change-Id: I1c85c6f29ae74cca0b594fc1f9ddae098b815e72
Reviewed-on: https://dart-review.googlesource.com/31860
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
2018-01-01 16:21:02 +00:00
Konstantin Shcheglov
0fb3ff477f
Issue 31589. Return only unique top-level declarations.
...
R=brianwilkerson@google.com
Bug: https://github.com/dart-lang/sdk/issues/31589
Change-Id: Ife9c607071bba90afb04ceb828203664fab49861
Reviewed-on: https://dart-review.googlesource.com/28122
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2017-12-11 16:54:33 +00:00
Jens Johansen
22d0696d91
[CFE] Move front-end API under src/
...
This CL deprecates the front-end API and moves it into src/api_prototype.
For now all usages have been updated to point to the new location,
but they should be updated to use custom-client invocations instead (e.g.
one specific way for DDC, another for dart2js etc.)
Bug:
Change-Id: I9b4f41f6ebf55d42510fd35240d942d1dc7292d6
Reviewed-on: https://dart-review.googlesource.com/24822
Commit-Queue: Jens Johansen <jensj@google.com >
Reviewed-by: Kevin Millikin <kmillikin@google.com >
2017-12-01 08:42:16 +00:00
Konstantin Shcheglov
5ea30b4e3d
Rename performace_logger.dart to performance_logger.dart
...
R=paulberry@google.com , sigmund@google.com
Bug:
Change-Id: Ib7b6d122dff3ddabde3db2270daa777a269e04ed
Reviewed-on: https://dart-review.googlesource.com/18512
Reviewed-by: Sigmund Cherem <sigmund@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2017-11-03 20:24:00 +00:00
Konstantin Shcheglov
1b4239d2e4
Export ByteStore and its implementations from front_end.
...
R=ahe@google.com , paulberry@google.com , sigmund@google.com
Bug:
Change-Id: Ie2e3413a7f143e270cec2bd3ae4564ad7cc315b1
Reviewed-on: https://dart-review.googlesource.com/3840
Reviewed-by: Sigmund Cherem <sigmund@google.com >
Reviewed-by: Paul Berry <paulberry@google.com >
2017-09-07 19:23:21 +00:00
Paul Berry
89c910b9c1
Move byte_store.dart and file_byte_store.dart to their own subdirectory.
...
This allows us to use the subpackage relationships test to verify that
they don't import any other parts of front_end, which paves the way
for the possibility of moving them to their own package in the future.
R=scheglov@google.com , sigmund@google.com
Review-Url: https://codereview.chromium.org/2990323002 .
2017-08-07 11:04:48 -07:00
Konstantin Shcheglov
00d5012906
Format analyzer, analysis_server, analyzer_plugin, front_end and kernel with the latest dartfmt.
...
...instead of mixing formatting with actual changes in many CLs.
R=ahe@google.com , paulberry@google.com , sigmund@google.com
BUG=
Review-Url: https://codereview.chromium.org/2975253002 .
2017-07-13 16:28:18 -07:00
Konstantin Shcheglov
e0f4c7b467
Report only private members in the same library as overrides.
...
R=brianwilkerson@google.com
BUG=
Review-Url: https://codereview.chromium.org/2959273002 .
2017-06-28 13:47:33 -07:00
Konstantin Shcheglov
2b64bbed6a
Add SearchEngine.membersOfSubtypes().
...
R=brianwilkerson@google.com
BUG=
Review-Url: https://codereview.chromium.org/2962023002 .
2017-06-28 11:44:48 -07:00
Brian Wilkerson
53e01faa43
Remove unused implementation of SearchEngine and rename the driver-based implementation
...
R=devoncarew@google.com
Review-Url: https://codereview.chromium.org/2949823002 .
2017-06-21 09:33:51 -07:00
Brian Wilkerson
4da8380881
Convert more tests to use the new driver
...
R=scheglov@google.com
Review-Url: https://codereview.chromium.org/2939803002 .
2017-06-13 12:04:25 -07:00
Brian Wilkerson
7d26ff6d4f
Remove some more library directives
...
R=scheglov@google.com
Review-Url: https://codereview.chromium.org/2884233004 .
2017-05-17 08:02:08 -07:00
Brian Wilkerson
6b8a56cd7f
Switch the default from non-driver to driver in several tests
...
R=scheglov@google.com
Review-Url: https://codereview.chromium.org/2864813002 .
2017-05-07 08:34:16 -07:00
Konstantin Shcheglov
7d2447d795
Replace computeNode() with AstProvider in search.
...
R=brianwilkerson@google.com
BUG=
Review-Url: https://codereview.chromium.org/2672973002 .
2017-02-03 10:40:44 -08:00
Konstantin Shcheglov
d2f48ccf58
Make subclasses of AbstractContextTest asynchronous.
...
As a preliminary step before duplicating them for the new analysis driver.
R=brianwilkerson@google.com
BUG=
Review-Url: https://codereview.chromium.org/2614033003 .
2017-01-05 14:21:29 -08:00
Konstantin Shcheglov
9ab69ab984
Implement SearchEngine.searchAllSubtypes() with the analysis driver.
...
Inline getSubClasses().
Add a couple of tests for SearchEngineImpl2 itself.
R=brianwilkerson@google.com
BUG=
Review-Url: https://codereview.chromium.org/2564913002 .
2016-12-09 09:32:49 -08:00
Konstantin Shcheglov
56bde6da28
Issue 27542. Guard against CompilationUnitElement is null in SearchMatch.element getter.
...
R=brianwilkerson@google.com
BUG= https://github.com/dart-lang/sdk/issues/27542
Review URL: https://codereview.chromium.org/2409403002 .
2016-10-11 14:09:09 -07:00
Konstantin Shcheglov
05a86a7495
Remove 'initializeTestEnvironment' from 'analysis_server'.
...
Also fixes the server_options_test.dart:22 test broken in https://codereview.chromium.org/2394683006/
R=paulberry@google.com , brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org/2402483002 .
2016-10-06 10:26:17 -07:00
Konstantin Shcheglov
de4d8b3a78
Switch analysis_server to use 'package:test'.
...
I'm changing DEPS in the corresponding analyzer CL.
R=brianwilkerson@google.com , paulberry@google.com
BUG=
Review URL: https://codereview.chromium.org/2394683006 .
2016-10-06 08:47:15 -07:00
Konstantin Shcheglov
0d84e5e586
New test for multiple imports with the same prefix name.
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org/2200473002 .
2016-07-29 16:04:38 -07:00
Konstantin Shcheglov
a3b1936567
Fix for SearchEngine.searchMemberDeclarations() - search exact names.
...
R=pquitslund@google.com , brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org/2183263002 .
2016-07-26 14:47:32 -07:00
Konstantin Shcheglov
a6b93661fd
Fix two build failures - for typeProvider and findElement.
...
TBR
R=brianwilkerson@google.com , paulberry@google.com
BUG=
Review URL: https://codereview.chromium.org/2032893002 .
2016-06-01 18:54:10 -07:00
Brian Wilkerson
08241e9072
More strong mode clean-up
...
R=scheglov@google.com
Review URL: https://codereview.chromium.org/1947813002 .
2016-05-04 07:42:46 -07:00