Konstantin Shcheglov
94985b1178
Fix for crash when overriding a setter without parameters.
...
https://crash.corp.google.com/browse?q=product_name%3D%27Dart_analysis_server%27+AND+product.Version%3D%272.10.324558781-edge%2Bgoogle3-v2%27&stbtiq=&reportid=1f4a951a32533b7d&index=13#0
R=brianwilkerson@google.com
Change-Id: I7f96c67311e8f5e8698bead0d4d00b3968801c72
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/167903
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-10-16 16:16:03 +00:00
Keerti Parthasarathy
fdad84fa5b
Modify FileResolver / bytestore to keep track of invalidated cache elements.
...
Change-Id: I60cb1f5f04eb9a1ee34c50157d5ed2da92d408ec
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/167861
Commit-Queue: Keerti Parthasarathy <keertip@google.com >
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
2020-10-16 00:17:31 +00:00
Konstantin Shcheglov
6cc220ec63
Add FileResolver.linkLibraries(), fix null typeProvider.
...
Change-Id: I4222097336407736e4cf0c3e922e9fac8c762725
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/167840
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Reviewed-by: Keerti Parthasarathy <keertip@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-10-15 20:57:07 +00:00
Konstantin Shcheglov
aad1a677c0
Deprecate GenericTypeAliasElement
...
See also https://dart-review.googlesource.com/c/sdk/+/166680
Change-Id: I6018f3bf5796dcc8ab059aab5b29d01e7336581b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/167727
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-10-15 16:03:26 +00:00
Konstantin Shcheglov
9ef964853c
Use assertPropertyAccess2() in ExtensionOverrideTest for getters.
...
We don't want to check if it is setter, because it never is now.
R=brianwilkerson@google.com
Change-Id: Iab52ff670f12ab56811b850b6518a3b7d4ae7730
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/167724
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2020-10-14 19:46:30 +00:00
Brian Wilkerson
51b8dfb6fd
Remove the unreported access_private_enum_field diagnistic
...
If this diagnostic needs to be generated, then I can create an issue to
track that work, but I think we handle it by not defining the private
fields in our models, which means the issue is reported as an undefined
getter.
Change-Id: I8d220adf0d11b2c65f8953eec57a87f86f520d74
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/167100
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2020-10-14 19:36:43 +00:00
Konstantin Shcheglov
779a3219f3
Ignore names _$foo when there is a missing .g.dart part.
...
Change-Id: I5a103cd362318b4db292b5f41da9e56a60f6431d
Bug: https://github.com/dart-lang/sdk/issues/42832
Bug: https://github.com/dart-lang/sdk/issues/42977
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/166820
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2020-10-14 19:28:38 +00:00
Konstantin Shcheglov
fbfc723de7
Use CompoundAssignmentExpression instead of LHS element/type.
...
This adds some technical debt in form of using writeOrReadElement in
clients, which can be paid incrementally by migrating these places to
handling assignment like expressions one by one. Doing it all in one
CL was too much. But now the underlaying AST resolution will be
sound.
In the next breaking change we will remove
setAssignmentBackwardCompatibility(), so stop setting elements/types
for assignment targets.
Change-Id: I11626876cfed25653edb0cc18544aba51cef5965
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/165622
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-10-14 18:45:08 +00:00
Paul Berry
9249d7a678
Add assertion to make sure analyzer sets NullSafetyUnderstandingFlag.
...
Change-Id: Ic0e3681117cb9783be6ee5b92ba8f79978d6c9bc
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/167361
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Paul Berry <paulberry@google.com >
2020-10-14 15:25:17 +00:00
Paul Berry
d0fafb6329
Enable the null safety understanding flag in _computeResolvedLibrary.
...
This is the _compute function used by the migration tool. It needs to
set the null safety understanding flag in order to ensure that type
comparisons work properly when analyzing code that's already been
migrated.
Fixes #42308 .
Bug: https://github.com/dart-lang/sdk/issues/42308
Change-Id: I347b99a3a2cc772bb158b2ba8621ac7bb632653a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/167260
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Paul Berry <paulberry@google.com >
2020-10-13 16:15:47 +00:00
Paul Berry
a1e1a23353
Allow MockSdk's allow list to be configured.
...
This will be needed for NNBD migration unit tests, to verify that a
partially migrated package is interpreted properly.
Bug: https://github.com/dart-lang/sdk/issues/42308
Change-Id: Id36d08de00f7ee38c1b415b457ff0da0447a4546
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/167200
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
2020-10-12 23:58:32 +00:00
Brian Wilkerson
9d1883c290
Remove duplicate messages from the generated documentation
...
Change-Id: I621f737faf08784faae5d7715ed4b5603a564985
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/167080
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2020-10-12 17:54:02 +00:00
Brian Wilkerson
e98f5db3c4
Use the correct quote in markdown
...
Change-Id: If2fe99b7d1d9880674be294b08b352982b9c6c45
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/167020
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2020-10-11 15:56:42 +00:00
Brian Wilkerson
c2314f1a57
Unify two diagnostics for documentation purposes
...
Change-Id: Icd100bafd1222144688f68c1bc3d2a4a7c29d10d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/167001
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2020-10-11 15:56:40 +00:00
Brian Wilkerson
4322f2a518
Mark diagnostics for which documentation has been published as having published docs
...
Change-Id: I749bd5e35dbb2cb54f21fa8cb5f1ccc1ebf14c64
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/167040
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2020-10-11 15:38:20 +00:00
Konstantin Shcheglov
5b52dfccf5
Fix --default-language-version support.
...
Re: https://dart-review.googlesource.com/c/sdk/+/166790
Change-Id: Ic646f4cf8c59810e856722a9099cadd364bad96a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/166923
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-10-10 23:55:20 +00:00
Konstantin Shcheglov
863e958cad
Fix the issue with reusing LinkedElementFactory and supertype for Object.
...
Bug: https://buganizer.corp.google.com/issues/170429675
Change-Id: Ieaec29e8b09ce5cc9c02e7dce5919e8b56278910
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/166789
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-10-09 17:34:57 +00:00
Konstantin Shcheglov
694c8d0d6b
Update UP for FutureOr.
...
Bug: https://github.com/dart-lang/sdk/issues/43720
Change-Id: I9decd3a3b430f82e3e4bd0c4e6963cd3069f9adf
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/166786
Reviewed-by: Samuel Rawlins <srawlins@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-10-09 00:00:55 +00:00
Konstantin Shcheglov
63e0cd6955
Issue 43717. Update UP(FunctionType, unrelated) to UP(Object, unrelated).
...
Bug: https://github.com/dart-lang/sdk/issues/43717
Change-Id: Ib2fa861df24d010c768e4a06ba2bff175bbf88f4
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/166783
Reviewed-by: Samuel Rawlins <srawlins@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-10-08 23:42:45 +00:00
Paul Berry
2601fa6d78
Ensure that && and || expressions promote properly in unreachable code.
...
Bug: https://github.com/dart-lang/sdk/issues/40009
Change-Id: Ib06449624de9320f5229957511ebaaee92c75ec8
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/166606
Reviewed-by: Johnni Winther <johnniwinther@google.com >
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
2020-10-08 21:42:14 +00:00
Konstantin Shcheglov
132e2307e7
Report MAIN_FIRST_POSITIONAL_PARAMETER_TYPE
...
Bug: https://github.com/dart-lang/sdk/issues/43555
Change-Id: Ieacc710f1da1d92ab99337c6511a6b994e9bc0da
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/166780
Reviewed-by: Samuel Rawlins <srawlins@google.com >
2020-10-08 19:59:19 +00:00
Konstantin Shcheglov
0c342ae491
Fix crash when invalid default field formal parameter has annotation.
...
Change-Id: Iabb329f850195be981d80b0589d9f7851596c680
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/166740
Reviewed-by: Samuel Rawlins <srawlins@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-10-08 15:17:05 +00:00
Konstantin Shcheglov
103465c90c
Report MAIN_HAS_MORE_THAN_TWO_REQUIRED_POSITIONAL_PARAMETERS and MAIN_HAS_REQUIRED_NAMED_PARAMETER.
...
Bug: https://github.com/dart-lang/sdk/issues/43559
Change-Id: If74634187d411c0b008133b59c1c3e23e87319c3
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/166309
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2020-10-08 00:05:16 +00:00
Konstantin Shcheglov
4f760fa268
Store declared elements into linked nodes, get from them.
...
The previous approach was reverted.
Change-Id: Ib4b9d09d740511cd2ef76d663412a3358c7f666d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/166400
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2020-10-07 22:51:43 +00:00
Paul Berry
57932cfb4f
Ensure that conditional expressions promote properly in unreachable code
...
Change-Id: I8680b81b44be789a047238b1e2d008ff240e59c2
Bug: https://github.com/dart-lang/sdk/issues/40009
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/165405
Reviewed-by: Johnni Winther <johnniwinther@google.com >
2020-10-07 18:16:52 +00:00
Paul Berry
ed2f45d56d
Ensure that if statements promote properly in unreachable code
...
Bug: https://github.com/dart-lang/sdk/issues/40009
Change-Id: I04a5af558bb70b861d92b5379a8fb84489d5c9f4
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/165402
Commit-Queue: Paul Berry <paulberry@google.com >
Reviewed-by: Johnni Winther <johnniwinther@google.com >
2020-10-07 15:32:25 +00:00
Paul Berry
e933e91aaa
Reland "Flow analysis: promote to non-nullable on initialization"
...
This is a reland of 6a1c54ec30
Original change's description:
> Flow analysis: promote to non-nullable on initialization
>
> When flow analysis encounters a variable declaration of the form `T? x
> = expr;`, if the type of `expr` is `T`, then the variable is
> immediately promoted to type `T`.
>
> Fixes #43099 .
>
> Change-Id: Ia206fe0d50e2fdd9bdf637e13c85633d8490dbcc
> Bug: https://github.com/dart-lang/sdk/issues/43099
> Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/163841
> Commit-Queue: Paul Berry <paulberry@google.com >
> Reviewed-by: Bob Nystrom <rnystrom@google.com >
> Reviewed-by: Johnni Winther <johnniwinther@google.com >
> Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Bug: https://github.com/dart-lang/sdk/issues/43099
Change-Id: I7530bb0f7c24674a7b500558b89d50b35e045aca
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/166305
Reviewed-by: Johnni Winther <johnniwinther@google.com >
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Paul Berry <paulberry@google.com >
2020-10-07 13:14:55 +00:00
David Morgan
0efbb96545
Revert "Return declared elements for linked AST nodes."
...
This reverts commit 706ab39eba .
Reason for revert: Analyzer crash b/170276354
Original change's description:
> Return declared elements for linked AST nodes.
>
> For now only top-level nodes and elements, will do class members later.
>
> These changes would be useful to fix matching elements and nodes, e.g.
> https://github.com/dart-lang/sdk/issues/43153 or https://bit.ly/3jCfhVx
>
> Change-Id: I37861ba60b4e70f637019bf4f8a4d0d007c97965
> Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/166200
> Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
> Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
TBR=scheglov@google.com ,brianwilkerson@google.com ,srawlins@google.com
Change-Id: I0b13f9e4fbecf9cb0e4d059580837f79bd1cf2b2
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/166381
Reviewed-by: David Morgan <davidmorgan@google.com >
Commit-Queue: David Morgan <davidmorgan@google.com >
2020-10-07 07:33:00 +00:00
Konstantin Shcheglov
d758af07b5
Several changes to Cider library context.
...
I'm still not able to reproduce the "Missing library" issue.
But I making several changes that might help.
Change-Id: Ieed6f14351a109565d20019deae6bf6e72e78112
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/166306
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Reviewed-by: Keerti Parthasarathy <keertip@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-10-06 23:10:26 +00:00
Konstantin Shcheglov
706ab39eba
Return declared elements for linked AST nodes.
...
For now only top-level nodes and elements, will do class members later.
These changes would be useful to fix matching elements and nodes, e.g.
https://github.com/dart-lang/sdk/issues/43153 or https://bit.ly/3jCfhVx
Change-Id: I37861ba60b4e70f637019bf4f8a4d0d007c97965
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/166200
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-10-06 22:08:53 +00:00
Sam Rawlins
19ada0706e
Report indirectly exporting @internal typedef
...
This type of exposure was brought up by Lasse at https://github.com/dart-lang/sdk/commit/afbb8f9063eaabf80fd3dfcd67ff2d3c07be2395#r42686423 .
New "Indirect exposure" section in the doc: https://docs.google.com/document/d/130E4qfsjqRWtSNpIoNM628zVwGP-8W4J1P7W3wzJG8c/edit#
Change-Id: If38889b2134719804aa8cbaf613c8eb33cb6d949
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/166180
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Samuel Rawlins <srawlins@google.com >
2020-10-06 21:58:23 +00:00
Sam Rawlins
1df5c58d29
Analyzer: Move MustCallSuperVerifier to its own library
...
This will make it easier for upcoming bug fixes. Calling this verifier
in BestPracticesVerifier means it will only be run when hints are
enabled, perhaps boosting performance.
Also add a few more test cases.
Change-Id: If22ab02313d9f98f067ad4325b2f5ac473f4862c
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/164580
Commit-Queue: Samuel Rawlins <srawlins@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
2020-10-06 20:15:33 +00:00
Keerti Parthasarathy
168b7201d2
Fix finding third party analysis options.
...
Change-Id: If6792018fa9a4a64316be034dfa4b6e14c2e03d8
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/166124
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Keerti Parthasarathy <keertip@google.com >
2020-10-05 22:55:53 +00:00
Brian Wilkerson
8967e3b85b
Fix the offsets for diagnostics produced while validating analysis options files
...
Change-Id: I1417be1e77738b19728546c5caa449ae2e0e54c3
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/165980
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2020-10-05 15:59:26 +00:00
pq
71d2e6de69
lint diagnostic reporting for pubspecs
...
See: https://github.com/dart-lang/sdk/issues/43529
Change-Id: Iaf05102b3f6473913d900286c31779cdb1d59926
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/164249
Commit-Queue: Phil Quitslund <pquitslund@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2020-10-05 15:35:25 +00:00
Konstantin Shcheglov
d03dd09e0f
Report CompileTimeErrorCode.MAIN_IS_NOT_FUNCTION
...
Bug: https://github.com/dart-lang/sdk/issues/43557
Change-Id: I773cd09a164c37444b9765ebc445477467bb7665
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/165960
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-10-04 17:25:51 +00:00
pq
1ee70ab86c
check sub-expressions for @doNotStore
...
Change-Id: I3a54b3e84cb9f87ad7aefe5fc917bc0b6c890dc3
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/165921
Commit-Queue: Phil Quitslund <pquitslund@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2020-10-04 14:58:21 +00:00
Konstantin Shcheglov
090166c79d
Report CompileTimeErrorCode.UNDEFINED_IDENTIFIER read in compound assignment.
...
Bug: https://github.com/dart-lang/sdk/issues/42704
Change-Id: Ibf9557c97a05229151254ad0d33ecf27764dce7c
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/165941
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-10-03 16:32:01 +00:00
Konstantin Shcheglov
ba9355624c
Issue 1182. Use the initial type for extension instantiation.
...
Bug: https://github.com/dart-lang/sdk/issues/43590
Bug: https://github.com/dart-lang/language/issues/1182
Change-Id: I80366ad4f777eec299143a002bbdc9d92ba61a5b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/160883
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2020-10-02 23:44:41 +00:00
Konstantin Shcheglov
f516210208
Replace assertTypeParameterType() with the display string check.
...
Not that we include the promoted bound in the display string,
we can get back to checking these types just as strings.
R=brianwilkerson@google.com
Change-Id: Ie713e18082a3f5080ece039573098c998b8a2b98
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/165863
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-10-02 20:08:21 +00:00
Konstantin Shcheglov
3a59eafbe5
Include promotedBound into the TypeParameterType display string.
...
Change-Id: I7d34a041559875d34a66de4504b8df1b57497e55
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/165684
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-10-02 18:42:21 +00:00
Konstantin Shcheglov
3698091858
Use demoteType() on inferred type arguments.
...
Bug: https://github.com/dart-lang/language/issues/1182#issuecomment-702272641
Change-Id: I72d30f51aaf1d2651c1568cd68f37e5c7c03b582
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/165683
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-10-01 22:22:47 +00:00
Clement Skau
b4f49dc255
Revert "Flow analysis: promote to non-nullable on initialization"
...
This reverts commit 6a1c54ec30 .
Reason for revert: Triggers test failure:
https://ci.chromium.org/p/dart/builders/ci.sandbox/vm-kernel-precomp-linux-debug-x64/8247
Original change's description:
> Flow analysis: promote to non-nullable on initialization
>
> When flow analysis encounters a variable declaration of the form `T? x
> = expr;`, if the type of `expr` is `T`, then the variable is
> immediately promoted to type `T`.
>
> Fixes #43099 .
>
> Change-Id: Ia206fe0d50e2fdd9bdf637e13c85633d8490dbcc
> Bug: https://github.com/dart-lang/sdk/issues/43099
> Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/163841
> Commit-Queue: Paul Berry <paulberry@google.com >
> Reviewed-by: Bob Nystrom <rnystrom@google.com >
> Reviewed-by: Johnni Winther <johnniwinther@google.com >
> Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
TBR=paulberry@google.com ,scheglov@google.com ,rnystrom@google.com ,johnniwinther@google.com
Change-Id: I8549b48a734f527194ce11d82235b9d5c6e58185
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: https://github.com/dart-lang/sdk/issues/43099
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/165564
Reviewed-by: Clement Skau <cskau@google.com >
Commit-Queue: Clement Skau <cskau@google.com >
2020-10-01 08:41:15 +00:00
Konstantin Shcheglov
6a92616f52
Issue 43175. Report IMPLICIT_THIS_REFERENCE_IN_INITIALIZER in AssertInitializer.
...
Bug: https://github.com/dart-lang/sdk/issues/43175
Change-Id: I23ae1c8d6177e99e634d3b05236c5787a3a95b5d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/164901
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-10-01 02:02:31 +00:00
Paul Berry
6a1c54ec30
Flow analysis: promote to non-nullable on initialization
...
When flow analysis encounters a variable declaration of the form `T? x
= expr;`, if the type of `expr` is `T`, then the variable is
immediately promoted to type `T`.
Fixes #43099 .
Change-Id: Ia206fe0d50e2fdd9bdf637e13c85633d8490dbcc
Bug: https://github.com/dart-lang/sdk/issues/43099
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/163841
Commit-Queue: Paul Berry <paulberry@google.com >
Reviewed-by: Bob Nystrom <rnystrom@google.com >
Reviewed-by: Johnni Winther <johnniwinther@google.com >
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
2020-10-01 01:15:31 +00:00
pq
0195f4850b
cache doNotStore state
...
Change-Id: I74a0e6a9bb3bae23bd3e30b492481761407657ba
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/165147
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Phil Quitslund <pquitslund@google.com >
2020-09-30 13:50:14 +00:00
Brian Wilkerson
dfc3e2666e
Fix the formatting of a header
...
Change-Id: I9f0b7b564d71cf30fe3d5ac41e67c71ae3e3ee40
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/165146
Auto-Submit: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Kathy Walrath <kathyw@google.com >
Reviewed-by: Kathy Walrath <kathyw@google.com >
2020-09-29 23:42:08 +00:00
Brian Wilkerson
597588f698
Make additional requested changes to the diagnostic documentation
...
Change-Id: I30b1f44c957b0f7bc4d629e62e0d9aeca7560203
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/165001
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2020-09-29 19:42:07 +00:00
Konstantin Shcheglov
2b246127f7
Prepare to publish analyzer 0.40.4 and _fe_analyzer_shared 11.0.0.
...
Change-Id: I19d92bf9f107a82826c2d6d41f18315f25afc411
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/165040
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-09-29 18:46:27 +00:00
Konstantin Shcheglov
8de1bc0a07
Stop using getReadType() in nnbd_migration.
...
The packages 'analyzer' and 'nnbd_migration' tightly depend on each
other via MigrationResolutionHooks. I will publish analyzer 0.40.4
shortly after this CL lands.
Change-Id: I6f5e51f88e0020a1674ffb251712658e896170e7
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/164900
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Reviewed-by: Paul Berry <paulberry@google.com >
2020-09-29 17:18:25 +00:00