Commit Graph

5882 Commits

Author SHA1 Message Date
Brian Wilkerson 2c982b0c1f Enhance the command-line relevance table generator tool to support a map-reduce style of table generation
Change-Id: Ie0e26094b4cd6acaf864556d04d3de0415683cdc
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/186501
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2021-02-23 17:46:21 +00:00
Danny Tuppeny c4edcc4cfa [analyzer] Support separate insert/replace ranges for completions
Fixes https://github.com/Dart-Code/Dart-Code/issues/2998.

Change-Id: I8e989932c16dc97f704c79c06374c8d1d1881f7e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/186581
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2021-02-23 17:43:11 +00:00
Konstantin Shcheglov 917d61b92e Add only dart files to drivers.
Change-Id: I345d3481a9107b6eec1e7e8845e8181f9d12a1ed
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/186500
Reviewed-by: Samuel Rawlins <srawlins@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2021-02-23 04:24:59 +00:00
Konstantin Shcheglov 8194c530e8 Handle ChangeType.REMOVE for any file, flush it.
Change-Id: Idb61bcb96ad5b6d29d46063fe46a9ae7413679a3
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/186440
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2021-02-22 22:05:20 +00:00
Sam Rawlins 9a673e4ae7 analysis_server: Remove unused dart: import
A bug in the analyzer is causing it to not report this unused import currently.
This PR is part of a cleanup to allow fixing the bug.

Bug: https://github.com/dart-lang/sdk/issues/45028
Change-Id: I2306306e1e51d141c6ba8aa29b7b655fac7b36fc
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/186384
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Samuel Rawlins <srawlins@google.com>
2021-02-22 22:05:00 +00:00
Konstantin Shcheglov f1094d5c3a Use newPubspecYamlFile() to create pubspec.yaml files
Change-Id: I181a3f3f14810019731201bf43e27befa7bc5481
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/186420
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2021-02-22 21:32:00 +00:00
Konstantin Shcheglov 64757ef097 AbstractAnalysisServer.notificationManager is always provided.
Change-Id: Ic99fac81c734ec5d743e77b717e11753b6890b3b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/186382
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2021-02-22 20:50:29 +00:00
Konstantin Shcheglov 3f54b435e1 For for NPE in isInAnalysisRoot when the collection is not create yet.
Change-Id: Iee6142397e490fba84b7c56b976a2c75f4fb1648
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/186383
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2021-02-22 20:35:34 +00:00
Konstantin Shcheglov 41dd9e5bea Replace ContextManagerCallbacks.removeContext() with afterContextsDestroyed()
Change-Id: Ibd3dead3e2f117d29f336cd289b1483bcbe0e092
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/186380
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2021-02-22 20:28:40 +00:00
Danny Tuppeny 8f9cdb3b2f [analyzer] Remove LSP fix-all-in-file functionality
To be replaced by new functionality that works with LSP + original protocol.

Change-Id: I59627e2c4e99b0a6aa0eb850168c870e5390e03b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/186360
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2021-02-22 19:53:39 +00:00
Brian Wilkerson 191e95fa3e Fix the replace_conditional_with_if_else assist in null safe libraries (issue 45030)
Bug: 45030
Change-Id: I2a0946a490a1e69cab7d1bbac6c9efdabd8926c8
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/186200
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2021-02-22 18:20:59 +00:00
Konstantin Shcheglov a68d60090e Add util/file_paths.dart and use in ContextManagerImpl
Change-Id: Ibbf8ec0b0809fa17e073df6b61065f7e6278c7d7
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/186022
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Samuel Rawlins <srawlins@google.com>
2021-02-20 20:33:36 +00:00
Parker Lougheed 5ef1dcdcab [Analysis Server] Update font inclusions for API doc
Some of the weights we used were missing causing blurry text. I've also switched from Source Code Pro to Roboto Mono to be consistent with other Dart websites.

While not related I also updated the semver link to https.

Change-Id: Ifc4a10a05d795134caade2081045517426c21fc3
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/185941
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Devon Carew <devoncarew@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2021-02-20 16:48:56 +00:00
Konstantin Shcheglov 8d0a5dd6fa Fix AnalysisDomainTest on Windows.
TBR

Change-Id: I4920ef5bfcb60d652b286c04c58b4c30de13a2a1
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/186041
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Samuel Rawlins <srawlins@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2021-02-20 01:24:25 +00:00
Konstantin Shcheglov c2195fcc14 Rewrite to use AnalysisContextCollection in analysis_server.
Change-Id: Iee6b392711790d17c25a3c18fa1e9bdfe8b8cc4b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/185160
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2021-02-19 23:01:25 +00:00
Konstantin Shcheglov e4643d5809 Deprecate ElementVisitor.visitFunctionTypeAliasElement()
Change-Id: Ib5d364b77af7974d757626a0719604fa7ec1fec7
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/185902
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2021-02-19 22:21:15 +00:00
Keerti Parthasarathy dcf6b12270 Add CiderAssistComputer to compute assists for Cider.
Change-Id: I6087ccabda0c0749d0027b40ecad5050a2eb0431
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/185492
Commit-Queue: Keerti Parthasarathy <keertip@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
2021-02-19 15:08:34 +00:00
Konstantin Shcheglov 2e40e359e2 getElementDeclaration() can return null.
Change-Id: I2c8331d22191587991cd1782525d84f5044a79b6
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/185721
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2021-02-19 08:21:37 +00:00
Konstantin Shcheglov 9bfd416c45 Add ContextRoot.workspace, deprecated AnalysisContext.workspace, support included excludes in ContextLocatorImpl
Change-Id: Iecd324ad45b926ca6b0626f8bea4f479409154e8
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/185499
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2021-02-19 02:15:40 +00:00
Konstantin Shcheglov 9a30392588 Require Workspace for ContextBuilder.getAnalysisOption() and createSourceFactory()
Ideally we want to create Workspace only once, and pass it around.
I was not able to do this yet, because DAS ContextManager kind of
dynamically updates contexts and drivers. I expect to avoid this issue
by switching DAS soon to AnalysisContextCollection.

I will follow with a bigger CL that keeps Workspace in ContextRoot.

Change-Id: I3050ba65400e0e5aa73e6d5f8beae821db10a6ee
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/185498
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2021-02-19 00:54:30 +00:00
Brian Wilkerson bfe3a31cd4 Add a failing test for issue 45030
Change-Id: I59e9db21ef97286c137e635b1c8bdbd2991b98a5
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/185493
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2021-02-18 23:29:50 +00:00
Danny Tuppeny a6c14e8848 [analyzer] Insert imports after annotation of first import directive in file
Fixes https://github.com/Dart-Code/Dart-Code/issues/3104.

Change-Id: Ic91727c11cda1436662a52b737094ea87927047c
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/185220
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2021-02-16 21:32:50 +00:00
pq 4302f058dd disable legacy fix-all fix creation
Tests to be re-enabled when we wire-up `FixInFileProcessor`.  (Or maybe we want a different approach to testing fix all fixes entirely?  TBD.)

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

Change-Id: I66f83d06801a71143dcc770cc38d9e2f86782264
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/185180
Commit-Queue: Phil Quitslund <pquitslund@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2021-02-16 20:50:20 +00:00
Danny Tuppeny c8c49c7cc8 [analyzer] Handle creating new files from code actions
Fixes https://github.com/Dart-Code/Dart-Code/issues/3141.

Change-Id: I44d7f20962512988ff1d54c7b38b6a144f973a58
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/185140
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2021-02-16 18:54:39 +00:00
Brian Wilkerson 77da201b19 Add a fix for unnecessary_nullable_for_final_variable_declarations
Change-Id: Ibd6570c05f3a289fba72c42f3fc30e88649a9004
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/185000
Reviewed-by: Phil Quitslund <pquitslund@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2021-02-15 16:26:39 +00:00
Brian Wilkerson e6b5d2c7c0 Add the fix data file to analyzableFilePatterns
Devon noticed the other day that this was missing. I was curious so I
commented out all of the non-Dart file patterns and ran the tests. There
were no failures. There were failures when I also commented out the
file pattern for Dart files, so that much is being used. My guess is
that it would be better to remove the seemingly unused patterns, but
then I have to ask whether we shouldn't just remove this field and
replace uses by a check that the name ends in '.dart'. Let me know what
you think.

Change-Id: Icda44a6fa532989f86cdb52acb3bd0f7a5b28e20
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/184900
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2021-02-13 00:40:29 +00:00
Keerti Parthasarathy 5a97dc8fc2 Add lineinfo to CiderErrorFixes
Change-Id: Ic2b82c27a98794a456a43a129ccfc9bd1fc0c07a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/184841
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Keerti Parthasarathy <keertip@google.com>
2021-02-13 00:04:11 +00:00
Brian Wilkerson bf8b510a8b Use the type of literal keywords for relevance
This has little negative impact on the completion metrics and some
positive impact in several places. The impact is fairly small overall,
but still worth having in my opinion. The biggest improvement is at the
beginning of a statement. The overall changes in relevance and relevance
by element kind (lower is better) are:

                            shipping  |  keyword type    delta
all completions                4.013  |         3.930   -0.083
successful completions         3.995  |         3.912   -0.083

class                         28.359  |        28.325   -0.034
constructor                    4.739  |         4.739    0.000
enum                          12.928  |        12.928    0.000
instance member                3.273  |         3.153   -0.120
keyword dynamic              136.713  |       136.223   -0.490
keyword void                 239.200  |       227.453  -11.747
local function               161.336  |       161.340    0.004
local variable                 1.632  |         1.616   -0.015
parameter                      4.406  |         4.383   -0.023
prefix                       363.871  |       368.868    4.997
static member                  6.012  |         5.984   -0.028
top level member              12.443  |        12.443    0.000
type parameter               252.785  |       254.135    1.350

Change-Id: Ia449feb716bfd6150f0204885e05fc0e812f1448
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/184861
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2021-02-12 20:56:01 +00:00
Konstantin Shcheglov 51950ab881 Add Resource.parent2 that returns non-null Folder, add Folder.isRoot
A bigger version of than https://dart-review.googlesource.com/c/sdk/+/184381
This is breaking change, so we do this in steps.

Change-Id: I0c7212a073b605ade56657036543c604651810c7
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/184581
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2021-02-12 19:09:20 +00:00
Konstantin Shcheglov 875af7c991 Deprecated TypeProvider.futureType2/listType2/etc
Change-Id: Ia994be1e29b4d96b89d714beafcb9256a0cb4de6
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/184641
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2021-02-12 17:26:07 +00:00
pq 2d27b34b06 appliedTogetherMessages for fixable in file fixes
Change-Id: I674f0e79c5d7ce5c44bcbddff8e6866106e860c5
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/184621
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Phil Quitslund <pquitslund@google.com>
2021-02-12 17:10:23 +00:00
Konstantin Shcheglov 27e707268f Always crawl up in getOptionsFile()
Change-Id: I424cd625f05d9bc10ae0366e0332e96496633062
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/184580
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2021-02-11 23:24:11 +00:00
pq fbf07bc7b7 migrate towards a shared nonLintProducerMap
Introduces a new map datastructure and migrate BulkFixProcessor to use it.

Change-Id: I6294cce875ac5e5052b363282454af6dadf011f0
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/184320
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Phil Quitslund <pquitslund@google.com>
2021-02-11 18:37:30 +00:00
Danny Tuppeny 235292605e [analyzer] Filter code actions returned from LSP server based on params.context.only
Fixes https://github.com/Dart-Code/Dart-Code/issues/2854.

Change-Id: If6036a4361b68ae2daa66b99755dfa9b9a8adcfd
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/184464
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2021-02-11 18:16:20 +00:00
Konstantin Shcheglov 244964d893 Refactor ContextBuilder.createPackageMap() and createWorkspace() into static methods.
There are places when we need to call createWorkspace(), but we don't
have enough data to create full ContextBuilder, because we don't
know SdkManager.

Change-Id: I12ec5701ecab897bf1c49c478e8487c7ca348a29
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/184380
Reviewed-by: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2021-02-11 17:52:53 +00:00
Danny Tuppeny ab8335b4fd [analyzer] Don't fail to initialize LSP server with non-file:// workspace folders/roots
Change-Id: I52fa0620ef563ff0362cb86b24ffc287e8e007c6
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/184461
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2021-02-11 16:10:19 +00:00
Brian Wilkerson 1ee6459ded Fix a bug in addParameter handling
Change-Id: Id321108ce4fbd096ba79212f530486ec2318fba3
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/184205
Reviewed-by: Phil Quitslund <pquitslund@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2021-02-10 22:49:33 +00:00
Sam Rawlins b948c7ee26 analysis_server: Remove unnecessary imports
Change-Id: I153b993e5d7721ad71818f3bd29d5117a76f3f08
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/184280
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Samuel Rawlins <srawlins@google.com>
2021-02-10 18:24:36 +00:00
Konstantin Shcheglov b4409ea3b4 Deprecate FunctionType.element/typeArguments
Bug: https://github.com/dart-lang/sdk/issues/44629
Change-Id: I5009a1abd456f33738d3b5e2ecae24b269b20000
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/182700
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2021-02-10 17:17:58 +00:00
Devon Carew 3f8c508a94 [analyzer] don't analyze html files
Change-Id: I45fa266be055a7d6ca1c0ecb90dc8245fa8b4616
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/184102
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Devon Carew <devoncarew@google.com>
2021-02-10 15:52:24 +00:00
Devon Carew c290fc0eaf [analysis server] Fix an NPE in the diagnostic page
Change-Id: Ifafd1c75978aa9a5b6193139455926a6936b66ec
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/184100
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Devon Carew <devoncarew@google.com>
2021-02-10 01:14:17 +00:00
Konstantin Shcheglov bcbebc8fd5 Fix for resolving package: URIs with space in BazelPackageUriResolver.
Change-Id: I0de91dcb2438205b476dea99fa2231dd189ef094
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/184042
Reviewed-by: Keerti Parthasarathy <keertip@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2021-02-09 22:26:59 +00:00
pq 7b2dcad078 improved fix in file computation
Follow-up from: https://dart-review.googlesource.com/c/sdk/+/183700

Change-Id: I6d15b25a2dc4664fd3743763fedd83bf39bba794
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/184041
Commit-Queue: Phil Quitslund <pquitslund@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2021-02-09 22:24:54 +00:00
Danny Tuppeny cc7bd35516 [analyzer] Support completing argument names in function expression invocations
Fixes https://github.com/dart-lang/sdk/issues/42064.

Change-Id: I186bef47771a56844833fc908c183358955e11ee
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/183940
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2021-02-09 21:44:32 +00:00
pq db09afdd1f fix (all) in file processor
Change-Id: I092d99ab8dd7e16fe351cf475a7c935a2546d67c
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/183700
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Phil Quitslund <pquitslund@google.com>
2021-02-09 20:35:46 +00:00
pq 720a2af3bd appliedTogetherMessage consistency
Change-Id: I187719426677c6d473fc8e0377f91d6ae54b8751
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/183765
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Phil Quitslund <pquitslund@google.com>
2021-02-09 17:37:47 +00:00
Brian Wilkerson 8f05ecae6e In edit benchmark, wait for initial analysis before editing the file
Change-Id: I2dbf5df9fa87d5e7f58260bd311673d2c2b53bd9
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/183703
Reviewed-by: Devon Carew <devoncarew@google.com>
Reviewed-by: Danny Tuppeny <danny@tuppeny.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2021-02-08 21:23:44 +00:00
Brian Wilkerson cf2e85f035 Generalize FeatureComputerTest to make writing more tests easier
Also, fixed a small bug found by updating the code used to find the node.

Change-Id: Id64e66f4d50f70aaadd3e56e37a83b257d119b9b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/183181
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2021-02-06 01:24:28 +00:00
Brian Wilkerson c723dae62f Add missed tests for noSuchMethod relevance
Also renamed other tests in this directory to not duplicate the
directory name.

Change-Id: I8aec73c6e44ca05f385f21b32f9c5feef1df67ef
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/183121
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2021-02-05 18:33:57 +00:00
Lasse R.H. Nielsen 222b894d62 Change resolve for package:URIs to not remove package name.
A "package URI" is defined as one with a `package` scheme,
no authority, a first path segment terminated by `/` which
contains no escapes and is not all `.` characters.
This is the definition of package names accepted by .packages
as well: Valid path characters and not all dots.

Change-Id: I9a161d47732e8bf873d278774315c72a4a928823
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/117542
Commit-Queue: Lasse R.H. Nielsen <lrn@google.com>
Reviewed-by: Nate Bosch <nbosch@google.com>
2021-02-05 18:31:48 +00:00