Konstantin Shcheglov
eeaa9085ae
Issue 40394. Updates to switch / case validation.
...
No changes to enum validation yet.
Bug: https://github.com/dart-lang/sdk/issues/40394
Change-Id: I2cca426b5b59d18a6244622f84884a3747a07190
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/134888
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2020-02-07 22:38:40 +00:00
pq
15198ebad8
add pubspec caching to PubWorkspacePackages
...
See: https://github.com/dart-lang/linter/issues/29
Change-Id: Ifcd4ad359a43c9183ab42ed6bb0ebb3586c73afd
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/134861
Commit-Queue: Phil Quitslund <pquitslund@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2020-02-07 21:56:26 +00:00
Konstantin Shcheglov
6f6797e745
Add NullSafetyUnderstandingFlag, update APIs to use it.
...
DartType.== implementations ignore nullability if the flag is not true.
TypeSystem APIs eliminate nullability from types before doing anything.
Internally analyzer continues using actual nullability for types.
Package nnbd_migration opted into NullSafetyUnderstandingFlag.
Bug: https://github.com/dart-lang/sdk/issues/40500
Change-Id: Ifeea28c01adf1dc59ed2da675b4a62c6334d529a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/134865
Reviewed-by: Paul Berry <paulberry@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-02-07 21:38:06 +00:00
Brian Wilkerson
c6b0ee3931
Convert the remaining fix tests using a lint marker and remove the ability to use a marker
...
Several of the tests were testing conditions that cannot occur and hence
were either re-written or removed. There's one test that I couldn't get
working so I marked it as failing. I marked another test as failing
rather than remove it because I think we want to update the lint to
catch that case (it's failing because no lint is produced).
Change-Id: I852c3c4595b0993ce2a64cbd9da1b6c7339dd59b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/134880
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2020-02-07 20:22:26 +00:00
Konstantin Shcheglov
1f47e5b23d
Revert "Analyze SDK with non-nullable experiment enabled, update MockSdk."
...
This reverts commit 545b80ef0e .
Reason for revert: this is a breaking change for MockSdk users, actually much more serious issue for un-forking SDK. https://github.com/dart-lang/sdk/issues/40500
Original change's description:
> Analyze SDK with non-nullable experiment enabled, update MockSdk.
>
> Change-Id: I80264a6533045c33ed794a5938f6719f3b5a6d0b
> Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/134401
> Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
> Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
TBR=paulberry@google.com ,scheglov@google.com ,brianwilkerson@google.com
Change-Id: If8c3d8322986b01012fa76f9c928f35309c00e3e
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/134802
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-02-06 22:55:29 +00:00
Konstantin Shcheglov
6a2afca361
Convert SimpleIdentifier in setter to legacy.
...
Change-Id: Ia7728995353666445c7e9ebb9c1c215a34bc270d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/134800
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-02-06 22:52:38 +00:00
Mike Fairhurst
a98f4acd1a
[analyzer] Fix #32913 , no error for inferring a non-const type argument in a generic function used in a const location
...
Bug: 32913
Change-Id: I7e5ef10fdd9befdc7d8a19b2c5c5b91639c82666
Fixed: 33439
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/91105
Commit-Queue: Mike Fairhurst <mfairhurst@google.com >
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Reviewed-by: Paul Berry <paulberry@google.com >
2020-02-06 20:33:02 +00:00
Mike Fairhurst
a62b9c8d23
[analyzer] Add a recursive type visitor that can be stopped midtraverse.
...
Change-Id: I9c0b7b8866a44446e7b8044cba59aacd7ee93c72
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/134482
Reviewed-by: Paul Berry <paulberry@google.com >
2020-02-06 20:33:02 +00:00
Konstantin Shcheglov
545b80ef0e
Analyze SDK with non-nullable experiment enabled, update MockSdk.
...
Change-Id: I80264a6533045c33ed794a5938f6719f3b5a6d0b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/134401
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-02-06 18:04:02 +00:00
Konstantin Shcheglov
fe0735f959
Fix for constant dependencies when opt-out depends on opt-in.
...
R=brianwilkerson@google.com
Change-Id: I31bb8073fa1059e2edf8903b5fa604afb0f19f50
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/134571
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-02-06 00:55:20 +00:00
Paul Berry
fecab44f59
Migration: Improve the tracking of type parameter bounds.
...
This CL extends ElementTypeProvider so that it also tracks type
parameter bounds. This allows the FixBuilder to reason correctly
about the what generic function types will look like after migration,
and that in turn prevents it from trying to add unnecessary casts.
Change-Id: I3c909a3b5ba14bf9f2aad4e58d0981c1b7b5bdd2
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/134412
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Reviewed-by: Mike Fairhurst <mfairhurst@google.com >
Commit-Queue: Paul Berry <paulberry@google.com >
2020-02-05 20:51:49 +00:00
Konstantin Shcheglov
bf08df3141
Update TypeState.toString() to use getDisplayString().
...
Change-Id: Iee39d69c0ea5c3f05dc60c3664914e73a3034533
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/134418
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-02-05 20:27:19 +00:00
Brian Wilkerson
b211bc3d4c
Mark newly published diagnostics so that links will be generated
...
Change-Id: Id0b7edf54aea1d8841cd4746e5353877190717f7
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/134416
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2020-02-05 19:26:55 +00:00
Paul Berry
655fcda015
Migration: rework how ElementTypeProvider overrides element types.
...
Previously, each piece of analyzer code needed during the FixBuilder
stage of migration needed to use the ElementTypeProvider interface to
access element types (rather than reading the types from the elements
directly), in order to ensure that the proper post-migration types
were used when building fixes. This required a lot of plumbing, and
there was a high risk that we would accidentally fail to use the
indirection mechanism in a key location and access the elements
directly.
This CL changes the approach so that the ElementImpl classes
themselves are responsible for indirecting through
ElementTypeProvider. This means that we can back out all the
plumbing, and there is no risk of accidentally failing to use the
indirection mechanism.
Change-Id: Ic1a0acc37f0350fc13b487f73fc1ad5225d7a090
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/134360
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Reviewed-by: Mike Fairhurst <mfairhurst@google.com >
Commit-Queue: Paul Berry <paulberry@google.com >
2020-02-04 22:29:20 +00:00
Paul Berry
e218986f64
Sort declarations in assignment_expression_resolver.dart
...
Change-Id: I7c4b345132259f0d45621a8815fb9bc6e2877aff
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/134247
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
2020-02-04 22:29:20 +00:00
Konstantin Shcheglov
05dcf371e7
Remove 'withNullability' from TypeImpl.toString()
...
Bug: https://github.com/dart-lang/sdk/issues/40460
Change-Id: Icd967df0252a9fd7ff9941ca7158b7df0190c961
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/134384
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-02-04 21:19:06 +00:00
Konstantin Shcheglov
a1d232a9b4
Issue 40392. Report SWITCH_CASE_COMPLETES_NORMALLY when switch/case completes normally.
...
Bug: https://github.com/dart-lang/sdk/issues/40392
Change-Id: I15c80d0667be1c783cb21870b9f92ee98a4f3042
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/134245
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2020-02-04 17:46:48 +00:00
Konstantin Shcheglov
239a278b84
Remove TypeSystem.isOverrideSubtypeOf()
...
It is replaced with CorrectOverrideHelper.
Change-Id: Iab8162b9ffbca02000587ece1215717346b0a3a7
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/134203
Reviewed-by: Paul Berry <paulberry@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-02-03 23:02:16 +00:00
Konstantin Shcheglov
49e2ed34a2
Issue 40304. Use runtime type equality for checking overrides.
...
Bug: https://github.com/dart-lang/sdk/issues/40304
Bug: https://github.com/dart-lang/sdk/issues/40279
Change-Id: I55a27335cfa923297ee580de6e79df15de004879
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/134221
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-02-03 22:52:46 +00:00
Konstantin Shcheglov
1fff623c19
Use TypeSystemImpl instead of TypeProvider in DartObjectImpl.
...
We need to be able to use TypeSystemImpl in DartObjectImpl.== to
call runtimeTypesEqual() instead of DartType.==
Change-Id: I2021a0d86a7c304072fd8fee2d1a7e6e979100a8
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/134146
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2020-02-03 20:38:46 +00:00
Konstantin Shcheglov
a165b62561
Use CorrectOverrideHelper in InheritanceManager3.
...
Change-Id: I3ceee509d8e78b7f35cb4bb596beeee0d2d9aeb4
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/134148
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Reviewed-by: Paul Berry <paulberry@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-02-03 20:34:26 +00:00
Paul Berry
a97c23b939
Migration: plumb ElementTypeProvider through FlowAnalysisVisitor.
...
This ensures that when type promotion happens while running the fix
builder, the promoted types are the correct post-migration types.
Change-Id: I15fe2cd8a6399527ded782dbbf252f9aeb530827
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/134083
Commit-Queue: Paul Berry <paulberry@google.com >
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Reviewed-by: Mike Fairhurst <mfairhurst@google.com >
2020-02-03 19:59:38 +00:00
Paul Berry
763ce812ea
Migration: properly handle type parameter types with nullable bounds.
...
This required adding logic to the `TypeParameterType` case of the
`toFinalType` function, so that we look up the decorated type of the
type parameter bound, and convert it to a final type as well.
(Previously we were just using the bound stored in the element model,
which was in many cases the bounds from prior to migration, and hence
it was a `*` type so it behaved as though it was non-nullable).
This required moving `toFinalType` into the `Variables` class so that
it could look up the decorated types of type parameter bounds.
Fixes #40355 .
Change-Id: I53c2636aef6954500589e924b9755a297c2b30f9
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/134061
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Reviewed-by: Mike Fairhurst <mfairhurst@google.com >
2020-02-03 19:59:38 +00:00
Konstantin Shcheglov
bbb4ab9153
Include types of candidates into INCONSISTENT_INHERITANCE.
...
Change-Id: Ide9f7da4f4d70bdea53f44ea0a8cdc2daa560b01
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/134144
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-02-03 19:18:36 +00:00
Konstantin Shcheglov
1bfe26ea48
Extract CorrectOverrideHelper and use for checking mixin applications.
...
Change-Id: I33c7b2df51cda29721be56c624b44c4ed6126137
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/134095
Reviewed-by: Paul Berry <paulberry@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-02-02 07:07:04 +00:00
Janice Collins
aa916d6367
Add path parsing to pub support.
...
Change-Id: Ib4edee4d247bc9bb525d63bc527cecebe4e4a5ee
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/134100
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Janice Collins <jcollins@google.com >
2020-01-31 22:17:32 +00:00
Konstantin Shcheglov
bb6cab29b9
Check for correct overrides as the specification requires.
...
Specifically, we replace types of covariant parameters with `Object?`
or `Object` and use subtype check. Then we check types of covariant
formal parameters and corresponding overridden formal parameters.
It looks that NNBD related changes that are coming now require
such more precise following to the specification rules.
Change-Id: Idfa4e3a118050a1be79acce8c708b3aac07b5051
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/134043
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2020-01-31 19:35:23 +00:00
Johnni Winther
42246f7f96
[cfe,analyzer] Disallow type parameters on operator methods
...
This was never supported by the grammar but unfortunately allowed by
both the analyzer and the CFE.
Change-Id: Id669c934fe08eda41973d6d2cef8340da2e7d72c
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/133591
Commit-Queue: Johnni Winther <johnniwinther@google.com >
Reviewed-by: Paul Berry <paulberry@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Reviewed-by: Jens Johansen <jensj@google.com >
2020-01-31 14:05:02 +00:00
Konstantin Shcheglov
d550879d9d
Implement runtime type equality.
...
Change-Id: I603b5147d7d7e6d8e7267be9c861324b575f259d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/134041
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
Reviewed-by: Paul Berry <paulberry@google.com >
2020-01-30 22:59:43 +00:00
Sam Rawlins
637a801e64
Use 'enum' and 'mixin' with undefined getters, methods, operators, setters
...
Fixes #40177
Change-Id: I0b416a4e77d3d1c5afc1712301c5cf1ea4cfc8d9
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/133043
Commit-Queue: Samuel Rawlins <srawlins@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
2020-01-30 17:01:58 +00:00
Konstantin Shcheglov
e766a6f145
Use Never and Object? in NNBD bottom / top.
...
Bug: https://github.com/dart-lang/sdk/issues/40283
Change-Id: I2ebfc650b3d454bcd80f8f8ae33ed5311a23dd24
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/133880
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-01-30 04:05:50 +00:00
Konstantin Shcheglov
d74aadd647
Reuse checkGetter() in checkExtension().
...
Change-Id: I356fdc7bc16d0abaaa890e46bb9cce0ae548df16
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/133801
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-01-30 01:28:10 +00:00
Konstantin Shcheglov
acee34e0e8
Clean up GetterSetterTypesVerifier.
...
Change-Id: I278eb2c61bf7b7e71923776c9e2d226738b023b4
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/133762
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-01-29 21:21:00 +00:00
Konstantin Shcheglov
f6c7fe278f
Implement NullShortableExpressionImpl in MethodInvocationImpl.
...
Change-Id: Ifc6eba086fcf3a49aa1d3458d568bfd62a54a94f
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/133761
Reviewed-by: Paul Berry <paulberry@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-01-29 20:26:10 +00:00
Konstantin Shcheglov
b4698ffe72
Issue 39976. Treat UnknownInferredType as top.
...
Bug: https://github.com/dart-lang/sdk/issues/39976
Change-Id: Ie14f279323282e3143d5d936e3edc953cebd9ff2
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/133664
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-01-29 18:06:26 +00:00
Konstantin Shcheglov
e98085fdd8
Issue 40333. Verify types of static getters / setters.
...
Bug: https://github.com/dart-lang/sdk/issues/40333
Change-Id: I10f366d4f451a94f8afa7b30cd6daa99073d7eda
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/133665
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-01-29 18:05:36 +00:00
Konstantin Shcheglov
cb2d91c983
Convert to legacy members of Object and constructor elements.
...
These two are not related, but I just drop them together.
Change-Id: I5ac83551d4438c53f8e0461e81a0acc5393bc902
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/133680
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-01-29 06:00:22 +00:00
Konstantin Shcheglov
b3a1f053a3
Issue 40333. Extract GetterSetterTypesVerifier, report GETTER_NOT_SUBTYPE_SETTER_TYPES for NNBD.
...
Bug: https://github.com/dart-lang/sdk/issues/40333
Change-Id: I265d535956204644859b05d02dd39a0bfdc8c19a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/133640
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-01-29 02:37:14 +00:00
Konstantin Shcheglov
2bde0e119e
Support for searching references to imports when opt-in from opt-out.
...
Change-Id: I4b558296cfd1ef17ca7fa03d1551658d2ae6d578
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/133546
Reviewed-by: Paul Berry <paulberry@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-01-28 21:08:20 +00:00
Konstantin Shcheglov
209e70b2a7
Convert loadLibrary() to legacy when opt-in from opt-out.
...
Change-Id: I2834eac5522da3d5e20f54682fe1b7f0c78ea434
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/133482
Reviewed-by: Paul Berry <paulberry@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-01-28 21:08:00 +00:00
Lasse R.H. Nielsen
36a6b1b5ce
Analyzer: Don't do recursive flattening of FutureOr in await.
...
The current behavior (removing all outer `FutureOr`s,
then calling *flatten* on the result) was never specified as correct behavior.
Since Dart 2.0, the await has not recursively flattened futures,
so the static analysis behavior did not match run-time behavior.
Change-Id: Ie1da323aedb4b0f51e2c1e3eebe84552576c5f37
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/121846
Commit-Queue: Lasse R.H. Nielsen <lrn@google.com >
Reviewed-by: Leaf Petersen <leafp@google.com >
2020-01-28 11:16:07 +00:00
Konstantin Shcheglov
44dff4e24b
Issue 40221. NNBD_TOP_MERGE super-interfaces when checking for implementing the same generic class more than once.
...
Bug: https://github.com/dart-lang/sdk/issues/40221
Change-Id: I776ee76ced12ec9ab0838f9bac76a3ec9fdb71b5
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/133329
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-01-27 17:12:06 +00:00
Konstantin Shcheglov
b6fdba235e
Update NORM and type parameters handling to new understanding.
...
Change-Id: I5df83667b4016651a15182c22a621eb59c387feb
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/133410
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-01-27 00:32:54 +00:00
Brian Wilkerson
7d7643c2ad
Add newly reviewed docs and change section header everywhere
...
Change-Id: I337fe5764b9167240b42cf75f908a3d36ef08cc3
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/133407
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2020-01-26 22:56:45 +00:00
Konstantin Shcheglov
f5abdf27a7
Split NormalizeHelper.
...
Change-Id: I93129d886d9cd6722147fda217d3d4d69a76841a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/133403
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-01-25 21:45:45 +00:00
Konstantin Shcheglov
7ebfc3662f
Extract NORM implementation into NormalizeHelper.
...
R=brianwilkerson@google.com
Change-Id: I0f504d364887253c33f09cda3fb63377d1a0742e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/133400
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-01-25 18:10:45 +00:00
Konstantin Shcheglov
21ab021637
Use test Matcher for checking Element(s).
...
We have more elements that might be Member(s) because of isLegacy.
So, we need something more sophisticated for checking elements.
Change-Id: Ibbf661571bf56cd4e9bc067adf57e881619ff92a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/133325
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-01-24 22:21:14 +00:00
Konstantin Shcheglov
3f12134e60
Issue 40287. Don't report MISSING_DEFAULT_VALUE_FOR_PARAMETER for external and native methods.
...
Bug: https://github.com/dart-lang/sdk/issues/40287
Change-Id: I3ad4268321c2355573a058ad00c11276bff83796
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/133283
Reviewed-by: Paul Berry <paulberry@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-01-24 21:00:44 +00:00
Konstantin Shcheglov
691df73a15
Issue 40287. Don't report MISSING_DEFAULT_VALUE_FOR_PARAMETER for abstract methods.
...
Opens new issue: https://github.com/dart-lang/co19/issues/516
Bug: https://github.com/dart-lang/sdk/issues/40287
Change-Id: Ifd05e570b8411369cec296db52746ce4f144bbac
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/133201
Reviewed-by: Paul Berry <paulberry@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-01-24 20:19:28 +00:00
Paul Berry
8714a7fa1d
Abstract resolution calls to .isNullAware.
...
When migrating, we'll need to change some null-aware property accesses
and method calls to non-null-aware (due to the fact that the receiver
is non-nullable, or due to the new `?.` shortcut rules), so when
migration re-resolves, it will need to be able to override
resolution's determination of whether a given property access or
method call is null-aware.
Change-Id: I411f43fb937431e757d4dd9b968874db84158e47
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/133240
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
2020-01-24 19:58:43 +00:00