Commit graph

86516 commits

Author SHA1 Message Date
Paul Berry
16ed7df34f Flow analysis: clarify behavior of ifNullExpression_rightBegin.
Previously, it was unclear what information was stored in
_IfNullExpressionContext._previous.  It turned out that it was the
"shortcut state", i.e. the flow state if the LHS of the `??` was
non-`null`.  I've renamed variables and added comments to clarify
this.  Also, based on the implementation of
`ifNullExpression_rightBegin`, it looked like it might update
`_current`, but in fact it did not (because `tryMarkNonNullable`
always returns an `ExpressionInfo` whose `ifFalse` is unchanged); I've
refactored the code so that this is clearer, and added a comment
explaining why it is the right thing to do.

Bug: https://github.com/dart-lang/language/issues/2020
Change-Id: Ib8a5235f9b9482f4b290ad90686385514660a95d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251142
Reviewed-by: Johnni Winther <johnniwinther@google.com>
Commit-Queue: Paul Berry <paulberry@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
2022-07-18 14:51:24 +00:00
William Hesse
145a9230de [test] Change default branch for test runner to main
Change-Id: Id5f6676c916810b6d4748dda1aff3ee4438a112b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251764
Commit-Queue: William Hesse <whesse@google.com>
Reviewed-by: Michael Thomsen <mit@google.com>
2022-07-18 12:48:33 +00:00
Konstantin Shcheglov
ea7f3d4d96 Support for metadata on augmentation directives.
Change-Id: Id05c1e2bbee6f3adc3399168065bb31f7ddeebfe
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251589
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2022-07-16 06:59:02 +00:00
Konstantin Shcheglov
54b7f4b72a Track the VariableElement associated with constant DartObjects.
The motivation for this functionality is lints which inspect the
declaration of constant values within Dart programs. By giving lints a
small amount of visibility into the intermediate values which were used
to construct constant values, it is possible for lints to validate not
just the resulting constant, but the means by which that constant was
constructed.

Change-Id: I75b3f46222ced88a0c7a7f7887de2994fcfa3f68
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251682
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2022-07-16 02:13:03 +00:00
Konstantin Shcheglov
a80178fb62 Add offsets for augmentation directives.
Change-Id: Id7a1a56110f5272b4a7006f54d1a5b8c6b7c64e3
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251660
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2022-07-15 21:06:00 +00:00
Liam Appelbe
844a9f3808 Reland "[ VM / Service ] Add abstract flag to Function"
This reverts commit 9b02bdaa76.

With https://dart-review.googlesource.com/c/sdk/+/251443 this is a
non-breaking change.

Bug: https://github.com/dart-lang/coverage/pull/412
Change-Id: Iaa8a74ab8065380d2a7e8a8fc07fec3a4518d979
TEST=Added to get_object_rpc_test.dart
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251480
Commit-Queue: Ben Konyi <bkonyi@google.com>
Reviewed-by: Ben Konyi <bkonyi@google.com>
2022-07-15 18:30:20 +00:00
Danny Tuppeny
027618092a [dartdev] Fix flakey LSP server test
This test was written to assume that the stdout stream would deliver LSP headers and body in separate "packets", but wasn't guaranteed to be the case. The failure at https://dart-ci.appspot.com/log/pkg-linux-release/unittest-asserts-release-linux/19779/pkg/dartdev/test/commands/language_server_test shows that both header+body arrived together which caused the test to fail.

These changes buffer the output until the complete message is available and then return the body of the message.

Change-Id: I5a5ec49fdca667ae351e602ca2d589fd2ab06ba3
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251548
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2022-07-15 17:44:30 +00:00
Konstantin Shcheglov
2e86c1f018 Deprecate AnalysisDriver.dispose(), use dispose2() instead.
Change-Id: Icfb46bf83f3a1f5828efd76eab1014c4dee0e088
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251587
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2022-07-15 17:15:40 +00:00
Konstantin Shcheglov
eb210a4c6f Add documentation comments for DirectiveUri getters.
Change-Id: Ia7003c8de1fb1e4e3ca03f4d2896d070bab04cdc
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251582
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2022-07-15 15:58:31 +00:00
Konstantin Shcheglov
a5b598afa6 Support for imports / exports in augmentations.
Change-Id: Ia0aa5fd599da51e52b9c0c8b3356bd23059c3292
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251583
Reviewed-by: Samuel Rawlins <srawlins@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2022-07-15 15:48:33 +00:00
Danny Tuppeny
0482fa6fb3 [analysis_server] Don't 'await' between calling function and using expect(throwsA)
This introduces a race where if the function throws before `expect(throwsA)` adds a handler, it becomes an unhandled exception.

Fixes https://github.com/dart-lang/sdk/issues/49455.

Change-Id: I81205f272c9ec211b99bf73af64dab8e4d774e84
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251550
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2022-07-15 15:40:40 +00:00
Konstantin Shcheglov
6a9f976ef1 Update LibraryFileStateKind.files to return only valid parts.
Change-Id: I189b74e76138f0aced88c6a8b1ecc1a156eef367
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251584
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Samuel Rawlins <srawlins@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2022-07-15 15:40:30 +00:00
Alexander Markov
025bfc858e [vm] Fix yield in async* to check if the stream was canceled while generator was suspended
Previously there was a window between the decision to resume generator
and actually running the micro-task. The stream could be canceled
during that window, making running the generator incorrect.

The solution is to check if the stream was canceled right before
resuming the generator in yield/yield*.

This change also unifies yield and yield* to check if the stream
was canceled even before suspending the generator.

TEST=language/async_star/cancel_while_paused_test,
language/async_star/cancel_while_paused_at_yield_test

Fixes https://github.com/dart-lang/sdk/issues/49451

Change-Id: Ib8ff3a2da9a6a7da8766a7dbf28e2c9d618728f9
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251562
Commit-Queue: Alexander Markov <alexmarkov@google.com>
Reviewed-by: Martin Kustermann <kustermann@google.com>
2022-07-15 14:09:20 +00:00
Michael Debertol
357d4a556b Fix documentation of num.remainder
Closes https://github.com/dart-lang/sdk/pull/49378

GitOrigin-RevId: f668688317d9eac62b5e629c5a450be98c830959
Change-Id: I9381e3ec6ea10efdc1f7da4f59cf4b64a0908f73
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/250400
Commit-Queue: Lasse Nielsen <lrn@google.com>
Reviewed-by: Lasse Nielsen <lrn@google.com>
2022-07-15 12:57:19 +00:00
Daco Harkes
0f456a845c [vm] Check for undefined symbols in assembly snapshots
We don't check undefined symbols in our assembly snapshots. We
currently never emit undefined symbols, because Dart code only refers
to Dart code statically.

When adding static linking, we would like to have the option to have
PC relative calls to native libraries provided as relocatable files
(object files or static libraries).

Not checking would compile the symbols to dynamic linker, but we don't
support that `dart compile exe` at the moment. So we should add this
sanity check.

Also: Removes unused imports in relevant test.

Bug: https://github.com/dart-lang/sdk/issues/49418
Change-Id: I10701b82a1e8a06ce41271bd9183064addfb88f4
Cq-Include-Trybots: luci.dart.try:vm-kernel-precomp-linux-debug-x64-try,vm-kernel-precomp-nnbd-mac-release-arm64-try,vm-kernel-precomp-nnbd-linux-debug-x64-try,vm-kernel-precomp-win-debug-x64c-try,vm-kernel-precomp-mac-product-x64-try,vm-kernel-precomp-dwarf-linux-product-x64-try
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251261
Reviewed-by: Tess Strickland <sstrickl@google.com>
Commit-Queue: Daco Harkes <dacoharkes@google.com>
Reviewed-by: Jonas Termansen <sortie@google.com>
2022-07-15 11:32:35 +00:00
Alexander Thomas
da31d6f667 [infra] Remove builder detection from co19 roll scripts
Change-Id: Idf018c2cd33be10ef62310230f90f891937d84ae
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251547
Reviewed-by: Erik Ernst <eernst@google.com>
2022-07-15 07:29:54 +00:00
Alexander Thomas
90bd16550d [infra] Upgrade checked-in SDKs to 2.18.0-271.0.dev
Tested: Builds on the CQ, built locally.
Change-Id: I25d0286d43199f4012a21e2223b1046a61a86bb9
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251545
Commit-Queue: Alexander Thomas <athom@google.com>
Reviewed-by: Ryan Macnak <rmacnak@google.com>
2022-07-15 04:48:41 +00:00
Konstantin Shcheglov
1a69106f26 Write details for library cycles only once.
Change-Id: I350a9b26426fd6e8da268a09e0995c0899443ccb
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251585
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2022-07-14 22:08:49 +00:00
Jaime Wren
d61562d765 Extend the LSP Analysis Server support to include the DetachableFileSystemManager support
The DetachableFileSystemManager API also changes slightly with this change resolving a TODO.

Change-Id: I388b352c987e6c96f95fcabd9a532cbfcfa39e4f
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251580
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Jaime Wren <jwren@google.com>
2022-07-14 21:10:39 +00:00
Danny Tuppeny
0213854523 [analysis_server] Don't provide commit characters on every completion item when enabled
Setting commit characters on the registration is now enough to apply to all items (see https://github.com/microsoft/vscode-languageserver-node/issues/673).

Change-Id: I1133005773e63f563d4e303af60f6c5bb56ec826
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251546
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2022-07-14 20:11:59 +00:00
Konstantin Shcheglov
cbadb50b95 Build LibraryAugmentationElement(s) and AugmentationImportElement(s).
Change-Id: Ibb5491f151359345470083a23148c7f459f2c890
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251560
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2022-07-14 17:58:34 +00:00
Gary Qian
03e5f9f941 Revert "Reland "[vm] Generate event ids for synchronous begin and end events.""
This reverts commit 05e5664ad6.

Reason for revert: Blocking Flutter engine -> framework roll, https://github.com/flutter/flutter/pull/107653/checks?check_run_id=7341814911

Invalid argument(s): durations is empty!
package:flutter_driver/src/driver/timeline_summary.dart 414:7   TimelineSummary._averageInMillis
package:flutter_driver/src/driver/timeline_summary.dart 72:12   TimelineSummary.computeAverageFrameRasterizerTimeMillis
package:flutter_driver/src/driver/timeline_summary.dart 232:47  TimelineSummary.summaryJson


Original change's description:
> Reland "[vm] Generate event ids for synchronous begin and end events."
>
> TEST=Instruments
> Bug: https://github.com/dart-lang/sdk/issues/49178
> Change-Id: I5ecb76e468d32e120de338e802ec313a7f50a49c
> Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251144
> Commit-Queue: Ryan Macnak <rmacnak@google.com>
> Reviewed-by: Siva Annamalai <asiva@google.com>

TBR=rmacnak@google.com,asiva@google.com

Change-Id: I52fffe00ec141a486241fa8719d4cf12df168384
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: https://github.com/dart-lang/sdk/issues/49178
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251561
Commit-Queue: Ryan Macnak <rmacnak@google.com>
Reviewed-by: Ryan Macnak <rmacnak@google.com>
2022-07-14 17:21:25 +00:00
Alexander Markov
2ad557a892 [vm] Cleanup more async-related code
This change continues cleanup of async implementation in the VM.

TEST=ci

Issue: https://github.com/dart-lang/sdk/issues/48378
Change-Id: Icdaeab18bcdc0d6974bc45841b630822cd1ac114
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251441
Reviewed-by: Martin Kustermann <kustermann@google.com>
Commit-Queue: Alexander Markov <alexmarkov@google.com>
2022-07-14 16:04:54 +00:00
Konstantin Shcheglov
9391343387 Invoke analyzeFiles() from handleAffectedFiles() only for analyzed files.
Bug: https://github.com/dart-lang/sdk/issues/49404
Change-Id: I6e80394d28a51182b622ab113a5a6376dbde13ef
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251442
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2022-07-14 14:54:14 +00:00
Danny Tuppeny
57a3598b2b [analysis_server] Check Call Hierarchy target is still valid before returning calls
Change-Id: I7d915700dd323381adab4d3bd22d5fb384c6de00
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251540
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2022-07-14 14:29:54 +00:00
Alexander Thomas
5249cd9294 [release] Bump version to 2.19
Tested: Standard CQ
Change-Id: Ic52d4d38a5b117dfcdc778dedfac08315ca30a54
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251541
Commit-Queue: Alexander Thomas <athom@google.com>
Reviewed-by: William Hesse <whesse@google.com>
2022-07-14 14:14:55 +00:00
Alexander Thomas
f2bd1e9641 [release] Move CHANGELOG entries to 2.18
Change-Id: I35d887541c8de985b55daed7c732c0d8302d278a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251542
Reviewed-by: Johnni Winther <johnniwinther@google.com>
Reviewed-by: Alexander Markov <alexmarkov@google.com>
Reviewed-by: Lasse Nielsen <lrn@google.com>
2022-07-14 14:13:28 +00:00
Jens Johansen
e473caca03 [CFE] Refactor incremental_suite_refactor step #1
Change-Id: Ic509612e37654da6534b10f1309aa81387caf261
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251543
Reviewed-by: Johnni Winther <johnniwinther@google.com>
Commit-Queue: Jens Johansen <jensj@google.com>
2022-07-14 12:43:56 +00:00
Erik Ernst
fd01012db9 [co19] Roll co19 to 5e94d0db25a8d8dfb6b1320bdb342e2935faf1d0
2022-07-13 athom@google.com Add initial specparser workflow (dart-lang/co19#1364)
2022-07-07 sgrekhov22@gmail.com Fixes dart-lang/co19#1355. Expect that `Process.killPid` returns `false` only if process is already dead (dart-lang/co19#1357)
2022-07-06 sgrekhov22@gmail.com Fixes dart-lang/co19#1328. Fix error expectation places for CFE (dart-lang/co19#1353)
2022-07-05 sgrekhov22@gmail.com Fixes dart-lang/co19#1309. Update error expectations according to the current behavior (dart-lang/co19#1352)
2022-07-05 dacoharkes@google.com Fix finalizer tests (dart-lang/co19#1338)
2022-07-04 sgrekhov22@gmail.com Fixes dart-lang/co19#1343. Use correct 'part' and 'part of' directives (dart-lang/co19#1349)
2022-07-04 asashour@yahoo.com Fix typos (dart-lang/co19#1341)
2022-07-04 sgrekhov22@gmail.com Fixes dart-lang/co19#1340. Update expected error locations for CFE (dart-lang/co19#1348)
2022-07-04 sgrekhov22@gmail.com Fixes dart-lang/co19#1344. Wait for entryPoint is invoked before doing the test (dart-lang/co19#1346)
2022-07-01 sgrekhov22@gmail.com Fixes dart-lang/co19#1342. Expect STATIC_WARNING.INVALID_NULL_AWARE_OPERATOR for C?.foo (dart-lang/co19#1347)

Change-Id: I1d5b116297f4b94930988914de4c0e03b68b2b8d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251463
Reviewed-by: Alexander Thomas <athom@google.com>
2022-07-14 12:01:28 +00:00
Johnni Winther
27ae8cf6b2 [cfe] Add AdvancedInvalidationResult
The result of the advanced invalidation is recorded and used for
testing, replacing the 'expectsRebuildBodiesOnly' yaml property
with an 'advancedInvalidation' property.

Change-Id: I520d329b100c1a7be72d6eff9d277b8e94df3a2c
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251462
Commit-Queue: Johnni Winther <johnniwinther@google.com>
Reviewed-by: Jens Johansen <jensj@google.com>
2022-07-14 08:04:53 +00:00
Nate Biggs
386ad2ff46 [dart2js] Unland deferredSerialization flag
Change-Id: Id04cab15d8e81df9661390b1d4cc48d2767abded
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251243
Commit-Queue: Nate Biggs <natebiggs@google.com>
Reviewed-by: Sigmund Cherem <sigmund@google.com>
2022-07-14 01:00:43 +00:00
Ryan Macnak
c2058b0f40 [vm, compiler] Allocate only one SSA index to definitions, even those with pair representation.
Change the mapping between SSA indices and virtual registers from 1:1 to 1:2.

This shrinks the size of bit vectors used during optimizations, and leaves the size of bit vectors used during register allocation the same.

TEST=ci
Change-Id: I0c82ca7972f7efb30559f7e4869396f1eed757c5
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/250982
Reviewed-by: Slava Egorov <vegorov@google.com>
Commit-Queue: Ryan Macnak <rmacnak@google.com>
2022-07-13 23:27:33 +00:00
Ryan Macnak
05e5664ad6 Reland "[vm] Generate event ids for synchronous begin and end events."
TEST=Instruments
Bug: https://github.com/dart-lang/sdk/issues/49178
Change-Id: I5ecb76e468d32e120de338e802ec313a7f50a49c
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251144
Commit-Queue: Ryan Macnak <rmacnak@google.com>
Reviewed-by: Siva Annamalai <asiva@google.com>
2022-07-13 21:59:33 +00:00
Stephen Adams
a886326767 [dart2js] Don't store collection of methods with no side-effects
The annotation data is queried on demand rather than being precomputed.

Methods that don't throw are computed after computing side-effects.


Change-Id: I4e31f0b7df668d41a15dcafee0c84fc7249e0699
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251340
Commit-Queue: Stephen Adams <sra@google.com>
Reviewed-by: Nate Biggs <natebiggs@google.com>
2022-07-13 21:12:53 +00:00
Liam Appelbe
df2b0426df [ VM / Service ] Remove required from constructor params
The required keyword means that adding a field to a class is a breaking
change, and needs a major version bump instead of a minor one. All the
fields are already nullable, and the constructors all use named
parameters, so removing this keyword is a minor (non-breaking) change.

Bug: https://github.com/dart-lang/coverage/pull/412
Bug: https://buganizer.corp.google.com/issues/236964692
Change-Id: I410d0f4359c003696570dfb11e3e2f7f179fb9ee
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251443
Commit-Queue: Liam Appelbe <liama@google.com>
Reviewed-by: Ben Konyi <bkonyi@google.com>
2022-07-13 19:35:23 +00:00
Danny Tuppeny
f34d4d5f93 [analysis_server] Add support for LSP Call Hierarchy
Fixes https://github.com/Dart-Code/Dart-Code/issues/612.

Change-Id: Ic51d4be2340317443b5a1cdae83e6eeaac4fa06b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251460
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2022-07-13 18:45:03 +00:00
Danny Tuppeny
f0d3e1dd90 [analysis_server] Enable unawaited_futures lint and fix remaining violations
Change-Id: I44b56ba8e1bd9ed5ba3d85006eb5d615e5a2c9d6
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251461
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2022-07-13 18:40:53 +00:00
Ben Konyi
a75e9cd3ee Revert "[pkg/native_stack_traces] Support Mach-O dSYM debugging information."
This reverts commit 08c13f173c.

Reason for revert: Causing failures on simarm, simarm64, etc

Original change's description:
> [pkg/native_stack_traces] Support Mach-O dSYM debugging information.
>
> TEST=vm/dart{,_2}/use_dwarf_stack_traces_flag
>
> Bug: https://github.com/dart-lang/sdk/issues/43612
> Cq-Include-Trybots: luci.dart.try:vm-kernel-precomp-dwarf-linux-product-x64-try,vm-kernel-precomp-linux-product-x64-try,vm-kernel-precomp-mac-product-x64-try,pkg-mac-release-arm64-try,vm-kernel-mac-release-arm64-try,vm-kernel-precomp-nnbd-mac-release-arm64-try
> Change-Id: Icda21bb14dcc0cf4784cea118e6ba7dd4edd35aa
> Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/250381
> Commit-Queue: Tess Strickland <sstrickl@google.com>
> Reviewed-by: Slava Egorov <vegorov@google.com>

# Not skipping CQ checks because original CL landed > 1 day ago.

Bug: https://github.com/dart-lang/sdk/issues/43612
Change-Id: I020c29f7329e9b53a8fe0f4f4a4de4070fca0ec3
Cq-Include-Trybots: luci.dart.try:vm-kernel-precomp-dwarf-linux-product-x64-try,vm-kernel-precomp-linux-product-x64-try,vm-kernel-precomp-mac-product-x64-try,pkg-mac-release-arm64-try,vm-kernel-mac-release-arm64-try,vm-kernel-precomp-nnbd-mac-release-arm64-try
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251242
Reviewed-by: Ben Konyi <bkonyi@google.com>
Reviewed-by: Alexander Markov <alexmarkov@google.com>
Commit-Queue: Ben Konyi <bkonyi@google.com>
2022-07-13 16:15:45 +00:00
Ahmed Ashour
b3df7ce795 [analyzer] remove BulkFixProcessor.fixOfTypeInUnit
Fixes #49406

Change-Id: Ib755f918f91ceca1ac4c282e18a9eab9224882e2
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/250746
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2022-07-13 16:05:13 +00:00
Danny Tuppeny
4bafe2233c [analysis_server] Has containerName to Call Hierarchy items
Change-Id: Ic39900ef0ef80b721eae645d1e7e1aa7b5b03661
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251266
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2022-07-13 14:22:53 +00:00
Ahmed Ashour
0813000fe4 [analysis_server] associate RemoveAbstract with ABSTRACT_FIELD_CONSTRUCTOR_INITIALIZER
Fixes #49365

Change-Id: Ibb0b2b3a0431e6c2770a214045fd94788c85f62b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/250161
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2022-07-13 14:20:33 +00:00
Alexander Markov
da18c7c9a7 [vm] Fix type of Future returned from async closure created in a factory
In order to create a Future for the result of async closure,
closure needs to instantiate a type argument of its result type.
The result type may reference type arguments of enclosing function or
class and scope builder should visit closure's result type
in order to capture receiver or type arguments variable of parent
factory.

TEST=runtime/tests/vm/dart/regress_49424_test.dart
Fixes https://github.com/dart-lang/sdk/issues/49424

Change-Id: I1cd131251717fca43f8ca95856d13718eb9aca68
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251320
Reviewed-by: Martin Kustermann <kustermann@google.com>
Reviewed-by: Slava Egorov <vegorov@google.com>
Commit-Queue: Alexander Markov <alexmarkov@google.com>
2022-07-13 14:09:53 +00:00
Alexander Thomas
3e74df1fbc [infra] Un-shard vm-kernel-precomp-mac-product-x64
Fixes: https://github.com/dart-lang/sdk/issues/49174
Cq-Include-Trybots: luci.dart.try:vm-kernel-precomp-mac-product-x64-try
Change-Id: I6e6c95e50ca4fdf9316e5a370de4c60e017e6a6f
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251262
Reviewed-by: William Hesse <whesse@google.com>
2022-07-13 10:34:05 +00:00
Jens Johansen
023cc8e24c [CFE] Be explicit about invalidation strategy for flutter gallery leak tester
Before we added the --experiment flag when enabling because the
alternative invalidation strategy is not on by default.
This CL makes it always pass the --experiment flag (i.e. with the no-
version when we don't want it) making any default not matter.

Change-Id: Id62da7bcdee52f4556092a49e4939b9b66829d51
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251265
Reviewed-by: Johnni Winther <johnniwinther@google.com>
Commit-Queue: Jens Johansen <jensj@google.com>
2022-07-13 08:09:12 +00:00
Johnni Winther
29d7be011e [cfe] Omit line/column from sdk constant coverage
This is done to avoid unnecessary dependency on sdk sources.

Change-Id: I5a72df4bb3a808a5a6398ae45ca587b43734314d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251264
Reviewed-by: Jens Johansen <jensj@google.com>
Commit-Queue: Johnni Winther <johnniwinther@google.com>
2022-07-13 06:52:14 +00:00
Ahmed Ashour
565a52571d [analysis_server] associate RemoveInitializer with ABSTRACT_FIELD_CONSTRUCTOR_INITIALIZER
Part of #49365

Change-Id: Icf4ef0fb89cbc514587b39bbe10a4d394290499a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/250162
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2022-07-13 04:50:42 +00:00
Konstantin Shcheglov
9303b6d07f Increment DATA_VERSION.
TBR

Change-Id: Id8ab379c9d2ab1eadb839bc3ee1910a4df377332
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251341
Commit-Queue: Samuel Rawlins <srawlins@google.com>
Auto-Submit: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Samuel Rawlins <srawlins@google.com>
2022-07-13 03:09:43 +00:00
Konstantin Shcheglov
210536e46f Use ExportDirectiveState to build LibraryElement.exports2, add ExportElement2.
Change-Id: I29242bb6f9514eccc93b1bef207ecd5b1e558571
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251143
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2022-07-13 01:48:34 +00:00
Stephen Adams
7a33665af5 [dart2js] Don't store collection of noInline/tryInline methods
Not storing a collection of methods is a step towards processing
annotations more 'online'.

Change-Id: I378ec4db9526004a1f1dc56886bbc91a7acde7f0
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251322
Commit-Queue: Stephen Adams <sra@google.com>
Reviewed-by: Nate Biggs <natebiggs@google.com>
2022-07-12 21:45:42 +00:00
Nate Biggs
bf996eb769 [dart2js] Migrate js_backend/enqueuer.dart
Change-Id: I8949e6a3ca083f33f55ceb2cf37bf09c5d69450d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/251124
Commit-Queue: Nate Biggs <natebiggs@google.com>
Reviewed-by: Mayank Patke <fishythefish@google.com>
2022-07-12 20:17:42 +00:00