Brian Wilkerson
08c5b9f8ff
Migrate more completion support
...
Change-Id: Ia55132ef8f4cd6e80dfc4fe16689e8b4e50cf387
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/194821
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
2021-04-09 22:40:03 +00:00
Danny Tuppeny
ea9c6484f1
[analyzer] Fix path format in test for windows
...
Change-Id: I20ddb29e18303ad38a29a98c8ace00ced858b120
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/194763
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2021-04-09 14:11:28 +00:00
Konstantin Shcheglov
bbbe5bfc87
Migrate several lib/src/services/correction/dart/
...
Change-Id: I8c50c6e7664a7bd8ee7b0d881d9adeaf9c544f61
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/194540
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2021-04-08 21:17:10 +00:00
Sam Rawlins
bc5d362959
analysis_server: Standardize on package:path/path.dart import prefix.
...
One file used 'pkg_path' which really threw me; I'd never seen it before. Two
more used 'pathos'. All other files in the package use 'as path', except a few
spots which do not use a prefix.
Change-Id: I94577c1783162c52c7f8dc3c6bf02e9a0b9159df
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/194500
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Samuel Rawlins <srawlins@google.com >
2021-04-08 20:02:50 +00:00
Brian Wilkerson
beea8076cd
Migrate more of server
...
Change-Id: I6342016847257ae95314e97b2f31186c43f10e6d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/194481
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2021-04-08 19:05:30 +00:00
Danny Tuppeny
e8d53cff92
[analyzer] Improve handling of loose files and context rebuilds
...
Change-Id: Ifd047a29953503a70216ce29b3fe4cdbfc4132df
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/192926
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2021-04-08 17:49:35 +00:00
Brian Wilkerson
b0a358c10b
Migrate two more tools in server
...
Change-Id: I5cd174caa77653cc39a37a8c0464f0f1e93c4a90
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/194320
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2021-04-08 01:03:34 +00:00
Konstantin Shcheglov
2af2f3559d
Migrate lib/src/services/correction/util.dart
...
R=brianwilkerson@google.com
Change-Id: Ie85217c57e26fc2430e916c8b7829d64ffddc4db
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/194210
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2021-04-07 20:52:03 +00:00
Brian Wilkerson
a0f7ff92a1
Migrate the first round of completion support
...
Change-Id: I64ca0b7b6d3040b6e37d328ed62e75059c48ef07
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/194212
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2021-04-07 20:44:58 +00:00
Brian Wilkerson
abd80dc17d
Migrate some tests in server
...
Change-Id: Ic7b3c155529dc241f3cd3ec4cc79ee60fb4295b6
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/194208
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2021-04-07 17:08:57 +00:00
Konstantin Shcheglov
c5769f6604
Migrate lib/src/search/workspace_symbols.dart
...
R=brianwilkerson@google.com
Change-Id: I14e70698e91db02f3e49ced438668d0d903bf349
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/194203
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2021-04-07 07:08:17 +00:00
Konstantin Shcheglov
d8da40ec52
Migrate lib/src/protocol_server.dart and related.
...
Change-Id: Ibb1e5a53aa8ad67fa43b315880c491093b051e20
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/194201
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2021-04-07 00:26:59 +00:00
Konstantin Shcheglov
43b5d134b3
Migrate lib/src/channel/
...
R=brianwilkerson@google.com
Change-Id: I2748f92589ef9501325535d79188fdbb103130f9
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/194118
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2021-04-06 23:16:43 +00:00
Konstantin Shcheglov
ad498f34dc
Migrate a few test/tool/completion_metrics/ libraries.
...
R=brianwilkerson@google.com
Change-Id: I8221b0c2f97ada211b101d31420e60062f30887d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/194115
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2021-04-06 22:58:53 +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
Danny Tuppeny
65050020f5
[analyzer] Add LSP integration test for diagnostic context messages
...
See https://github.com/dart-lang/sdk/issues/44907 .
Change-Id: I780e584a0e624aac232439d3f87cf1fb1284ef9f
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/193800
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2021-04-06 16:08:47 +00:00
Konstantin Shcheglov
b173c18796
Migrate LspPacketTransformer.
...
Change-Id: Ib0a84ae01b66e92a9406b559c1c8e4deb52ad3b4
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/194102
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2021-04-06 15:46:37 +00:00
Brian Wilkerson
4cba249477
Migrate a couple of additional libraries and some missed tests
...
Change-Id: I7c107b71a7b6226c8e294428a70656182353a048
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/194018
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2021-04-05 23:01:26 +00:00
Danny Tuppeny
06729f230a
[analyzer] Don't produce edits during MOVE_FILE for directives that don't change
...
Fixes https://github.com/dart-lang/sdk/issues/45593 .
Change-Id: I4110c5a6bc4a08caff7d40cd288ae554625703e8
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/194060
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2021-04-05 22:20:56 +00:00
Konstantin Shcheglov
4757152a0b
Migrate a few random analysis_server libraries.
...
Mostly no-ops.
Change-Id: Ia538aed657576203ec104bd849862bcc87025bef
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/194006
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2021-04-05 16:06:36 +00:00
Konstantin Shcheglov
87d9364e06
Update integration/analysis/navigation_test for non-function type aliases.
...
The test was passing for me without changes, but failing on bots.
I suspect that this is because of a random package_config.json on
my computer. Adding one explicitly in the test should fix it.
Bug: https://github.com/dart-lang/sdk/issues/45576
Change-Id: I0ccdca5713c4fd5aeac7732dc5736c4e8dbfea9e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/194003
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2021-04-05 15:24:26 +00:00
Konstantin Shcheglov
3ea23d2f55
Migrate pkg/analysis_server/test/integration/analysis/
...
Change-Id: I6dc636c06e13d1ac1da6caf2e33443baca08315d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/194001
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2021-04-05 07:46:16 +00:00
Konstantin Shcheglov
1c25329091
Migrate more analysis_server/test/integration/ tests.
...
Change-Id: Idbcf7a7c628a61f23120013a113b35256c26ed25
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/194004
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2021-04-05 06:19:15 +00:00
Brian Wilkerson
99814617b0
Migrate more of server to null safety
...
Change-Id: I8989f5f9a45a9c832f0aeb56397fed978386ce30
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/194041
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
2021-04-04 21:40:55 +00:00
Brian Wilkerson
34873853d8
Migrate some of the plugin support in server
...
Change-Id: I1294a33725ff0d0c3d2eb981c23211a8576f60f5
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/194023
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2021-04-04 00:23:39 +00:00
Konstantin Shcheglov
454d4db340
Use Object as the type for TypeUnion in analysis_server protocol generator.
...
Change-Id: I6772182341df26211ff245748afb983e9d1b6ef4
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/194021
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2021-04-03 19:44:24 +00:00
Brian Wilkerson
0190d20bd6
Migrate some tests and test utilities in server
...
Change-Id: I0a37352c903bf7139af25aab255fe6a5331ce98b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/194020
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2021-04-03 19:23:44 +00:00
Konstantin Shcheglov
a8590a287e
Remove WithNonFunctionTypeAliasesMixin from analysis_server tests, enabled by default, update tests.
...
https://dart-review.googlesource.com/c/sdk/+/192948 was landed.
Change-Id: If5c175af47c9b324d6ca06597a4ebc3e3541cf85
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/193962
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2021-04-03 05:19:42 +00:00
Brian Wilkerson
744fa0ba2d
Migrate some additional libraries and their tests
...
Change-Id: I3aae14488fb5def205788a60b27d33211c88d330
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/193889
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2021-04-02 20:02:22 +00:00
Brian Wilkerson
90d42351db
Migrate a few more utilities to null safety
...
Change-Id: I2b623713ec3a7c366f6fe7643e7c56bab54f40a9
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/193822
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
2021-04-02 17:53:32 +00:00
Brian Wilkerson
0f4943c22b
Migrate some of the base test classes in server
...
Change-Id: I010389d51d519968ce7c1ecd8da8811d036d9ab2
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/193830
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2021-04-02 14:53:31 +00:00
Konstantin Shcheglov
c2d660d161
Migrate analysis_server and analysis_server_client protocol.
...
Change-Id: Ie0912627733f0481de0d3239647a4978e5327f12
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/193641
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2021-04-02 06:46:41 +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
Brian Wilkerson
8c775581e2
Fix a bug in data-driven fixes handling of parameter changes
...
Change-Id: Ic5872a364bfcadc302ec35c0cf63ec87e5e2594b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/193444
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2021-03-30 04:15:38 +00:00
Konstantin Shcheglov
114d7b980a
Migrate analyzer_plugin package to null safety
...
Bug: https://github.com/dart-lang/sdk/issues/45236
Change-Id: I01175a2b2b1eb3ce6cdf30ade794d8186c6e8ead
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/191622
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2021-03-30 00:29:37 +00:00
pq
a68db103ae
rename lintProducerMap2 => lintProducerMap
...
(Also removes deprecated "legacy" lintProducerMap.)
Change-Id: I8c9222657029fe709228e010c4b90f34244814d6
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/193086
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Phil Quitslund <pquitslund@google.com >
2021-03-26 14:50:04 +00:00
Konstantin Shcheglov
92130a010e
Tests for DAS services and generic annotations.
...
Change-Id: I063c78ae778366e60bb0d4aca55c4e7fd70f3d52
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/193091
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2021-03-25 23:38:24 +00:00
pq
9847e7fbe6
migrate to lintProducerMap2
...
Change-Id: I90b41091b354f02e84772e797257bf20db404f30
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/192949
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Phil Quitslund <pquitslund@google.com >
2021-03-25 14:59:04 +00:00
pq
727d90540d
remove nonLintProducerMap
...
Change-Id: Iae2b150c2dffd8aa13197d08811eed63b707e072
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/192941
Commit-Queue: Phil Quitslund <pquitslund@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2021-03-24 23:12:03 +00:00
pq
67cf58cde8
unnecessary_final fix support
...
Change-Id: I79338f2001d621b83ae4234fd4a79321836167b1
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/192720
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Phil Quitslund <pquitslund@google.com >
2021-03-24 15:05:41 +00:00
Danny Tuppeny
387e9d9ab2
[analyzer] Include ConditionalExpressions in Flutter Outlines
...
Fixes https://github.com/Dart-Code/Dart-Code/issues/3196 .
Change-Id: I369e48285329c808a092ff677440e159aa7a103b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/192688
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2021-03-24 15:01:21 +00:00
Konstantin Shcheglov
7f3f3e66ac
Skip BazelChangesTest on Windows.
...
Change-Id: I88259cf2d101c80b35b16bec5cdefd3dc85a5356
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/192762
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2021-03-23 21:24:01 +00:00
Konstantin Shcheglov
86c5085565
Fix NPE when the return type of a method is inherited.
...
Change-Id: Iaf77f250c806b116f0f0d6bbd3d9b9ff2ab0090d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/192540
Reviewed-by: Phil Quitslund <pquitslund@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2021-03-22 21:03:45 +00:00
Michal Terepeta
6172458220
Trigger checks for generated files also on failed builds
...
Bug: http://b/183199080
Change-Id: If8a9baed10068f70d24a8831a093e4a4bf240303
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/192383
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Michal Terepeta <michalt@google.com >
2021-03-22 18:14:54 +00:00
Brian Wilkerson
ec04c1f335
Remove some unnecessary ignore comments
...
Change-Id: Iafa4b9c8aa5dc696c5746248a8701b4f6e875979
TEST=Existing tests.
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/191980
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
Reviewed-by: Nicholas Shahan <nshahan@google.com >
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Reviewed-by: Ben Konyi <bkonyi@google.com >
2021-03-18 19:58:43 +00:00
Brian Wilkerson
d00ef8611a
Update the server protocol to support passing back the line and column numbers for the end of a range
...
Change-Id: I8310e4a32cacbe98310c1dbaa3b3563b1ff1a1ee
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/191862
Reviewed-by: Danny Tuppeny <danny@tuppeny.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2021-03-18 19:22:23 +00:00
Michal Terepeta
9933192f36
Move watching generated Bazel files to an isolate
...
This does a few optimizations to improve the performance of the analyzer
when watching for generated files:
- We do all the polling in a separate isolate.
- We detect when Bazel finished running and only poll afterwards.
- We use a batch interface and deliver all changes at once (instead of
one by one). This allows us to avoid resetting caches more often than
necessary.
I had to remove one of the larger tests and created an integration test
instead, since the code for detecting the Bazel builds relies on
`dart:io` directly (`ResourceProvider` does not expose a way to
check for symlink targets).
Since this required a bit more code, I've decided to create a separate
file for it (`bazel_watcher.dart`).
Change-Id: I6c2383e7fd4348ab8af1af639b10db519c7a2f33
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/183010
Commit-Queue: Michal Terepeta <michalt@google.com >
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
2021-03-18 17:50:58 +00:00
Danny Tuppeny
44275c6001
[Analyzer] Add support for LSP experimental SnippetTextEdit
...
Change-Id: Id37a1954c71fb10c4968c5af6a873ad0ef864a5a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/191403
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2021-03-16 18:40:50 +00:00
Sam Rawlins
1cb203d8c9
Remove unused code and files from analysis_server:
...
* ManifestFixKind, PubspecFixKind, ImportElementInfo class
* WithNullSafetyMixin mixin
* suggestionComparator function
Change-Id: I9e332be6345b2f2b7b788bc4ae63a075a21cbe06
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/190821
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Samuel Rawlins <srawlins@google.com >
2021-03-16 05:08:24 +00:00
Danny Tuppeny
cf3dcc4256
[analyzer] Prevent MOVE_FILE using absolute URIs when moving files out of lib
...
Fixes part of https://github.com/dart-lang/sdk/issues/41889 , maybe part of https://github.com/dart-lang/sdk/issues/43602 .
Change-Id: Ic7a1e81a280e9786e26f0075ea079e0136e934b0
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/191142
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2021-03-15 18:42:44 +00:00