Commit Graph

81645 Commits

Author SHA1 Message Date
Jens Johansen 497a331365 [parser] Set 'recovered' in more cases
Fixes https://github.com/dart-lang/sdk/issues/47009
Fixes https://github.com/dart-lang/sdk/issues/47008

Change-Id: I4d00e378ad7cfe3b84fe0f48b11cb83ad7a14fc4
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212826
Commit-Queue: Jens Johansen <jensj@google.com>
Reviewed-by: Johnni Winther <johnniwinther@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Paul Berry <paulberry@google.com>
2021-09-10 08:18:17 +00:00
pq b533eed0fb master => main
Change-Id: Ib5abdd36858828fde46ee3898489ffd1362e99b2
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/213028
Reviewed-by: Alexander Thomas <athom@google.com>
2021-09-10 08:02:49 +00:00
Michael Thomsen dca853faca Add 2.14.1 to changelog
Also add release dates for 2.14.0 and 2.14.1

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

Closes https://github.com/dart-lang/sdk/pull/47182
https://github.com/dart-lang/sdk/pull/47182

GitOrigin-RevId: 0830cdc0bb4546a95a13458aa93134bb646e0dad
Change-Id: Ia7909f5cfb57d5a037d169889c3b6a1520cfb843
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/213060
Reviewed-by: Alexander Thomas <athom@google.com>
2021-09-10 07:57:35 +00:00
Sam Rawlins e319cfa6aa Enable in-line ignores per 'type' such as 'lint'
This uses the class ErrorType which may be an outdated field on ErrorCode, but it works for a prototype.

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

Change-Id: I98de8faf7f3ad738e9e27b0d5dd5add531b78b77
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/211460
Commit-Queue: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Phil Quitslund <pquitslund@google.com>
2021-09-10 01:30:27 +00:00
Konstantin Shcheglov 73d90bd400 Issue 47171. Apply Substitute also to InstantiatedTypeAliasElement.
Bug: https://github.com/dart-lang/sdk/issues/47171
Change-Id: Ifcc9ea79cdcd2cc55a876e25fc6bd6d710180d1b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/213022
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2021-09-10 00:38:38 +00:00
Brian Wilkerson 2a7237bd05 Include field in the element kinds associated with a property access
Fixes: https://github.com/dart-lang/sdk/issues/47173
Change-Id: Ic96ddfe00f7bd9fe3883abe6b6f30a1d5211908c
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/213024
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2021-09-09 23:53:47 +00:00
Konstantin Shcheglov bf9c829f82 Issue 47171. Don't store initializers of static final fields, even when has const constructor.
Bug: https://github.com/dart-lang/sdk/issues/47171
Change-Id: I22efdadaaa3348048f2b50a80795ae5c64870b47
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212874
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2021-09-09 23:32:57 +00:00
Sam Rawlins 3f53e574d4 analyzer: additional tests for invoking expressions from constructor and function tearoffs
While confirming things related to the staticElement of these tearoffs, I wanted to make sure that type checking of expressions derived from tearoffs are functional.

Change-Id: I83c48b03a620bdc5c3e81775fae48f2d5d3a39a1
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212801
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Samuel Rawlins <srawlins@google.com>
2021-09-09 22:42:17 +00:00
Stephen Adams cc9040245b [dart2js] Modernize allocations and initializations in universe/
- Use literals instead of Map/Set constructors.
- Make more use of inferred type arguments.
- Rewrite some conditionals to use `??`.

Change-Id: Ifb844226e29ccedb2b1b409e8e4f99bbdb96cfe5
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212401
Commit-Queue: Stephen Adams <sra@google.com>
Reviewed-by: Mayank Patke <fishythefish@google.com>
2021-09-09 21:10:57 +00:00
Ryan Macnak 9ab7c09356 [vm, compiler] Fix incorrect merging of doubles that are equal but not identical.
TEST=implicit_double_context_test (flaky)
Change-Id: I1c4d285897fb4dd3aae15323ab4e671bec88c564
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212870
Reviewed-by: Alexander Markov <alexmarkov@google.com>
Commit-Queue: Ryan Macnak <rmacnak@google.com>
2021-09-09 20:26:35 +00:00
Sam Rawlins 6d5de3d19c Remove unnecessary imports in vm_service
TEST=N/A

Bug: https://github.com/dart-lang/sdk/issues/44569
Change-Id: I61adbdb6666fee9f34372a83d4c3383b636f76e9
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212606
Auto-Submit: Samuel Rawlins <srawlins@google.com>
Commit-Queue: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Ben Konyi <bkonyi@google.com>
2021-09-09 19:03:44 +00:00
pq dd35db6192 "master->main" migration
Change-Id: I773e0a60a782f9e6678cea22e2a7d8fae48cffa3
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212869
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Phil Quitslund <pquitslund@google.com>
2021-09-09 18:14:36 +00:00
Alexander Markov d69828ee2f [vm/compiler] Fix nullability of LoadStaticField
TEST=vm/cc/TypePropagator_NonNullableLoadStaticField
Fixes https://github.com/dart-lang/sdk/issues/47119

Change-Id: I67b62895cbd8e79a19405b441ecca1f3ca4c9047
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212661
Commit-Queue: Alexander Markov <alexmarkov@google.com>
Reviewed-by: Slava Egorov <vegorov@google.com>
2021-09-09 17:44:31 +00:00
Alexander Markov d0ac9e2620 [Test tool] Pass --sound-null-safety to VM unit tests
This was probably broken since we stopped specifying
--sound-null-safety explicitly in test_matrix.json in
https://dart-review.googlesource.com/c/sdk/+/164160.

TEST=ci

Change-Id: I0a41f13749784db1a076aba434985327291ce71a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212660
Commit-Queue: Alexander Markov <alexmarkov@google.com>
Reviewed-by: Alexander Thomas <athom@google.com>
Reviewed-by: Slava Egorov <vegorov@google.com>
2021-09-09 17:43:01 +00:00
Alexander Markov be06aef0f9 [vm] Fix VM unit tests for sound null safety
This change fixes vm/cc/** unit tests for sound null safety.

Also, type propagation is slightly improved for int operations to
help AOT unit tests which don't run TFA and don't have type feedback.

TEST=tested with sound null safety enabled

Change-Id: I6c42b377d4fa8035c99e5fabf1de2ae52272b994
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212862
Commit-Queue: Alexander Markov <alexmarkov@google.com>
Reviewed-by: Slava Egorov <vegorov@google.com>
2021-09-09 17:22:01 +00:00
Alexander Markov c547e3e104 [vm/compiler] Improve elimination of dead CatchBlockEntry Parameters
This change improves elimination of dead ParameterInstr instructions
by skiping over Unbox instructions when tracing for real uses.

Previously, ParameterInstr were removed if they we used only by other
dead Parameters or as inputs to dead phis. Now, Unbox instructions
are also allowed as long as they are also dead.

TEST=vm/cc/TryCatchOptimizer_DeadParameterElimination_Cyclic1
(with sound null safety)

Change-Id: Iba807ce43d10ff6e400abd614cc749d60f2454e1
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212900
Commit-Queue: Alexander Markov <alexmarkov@google.com>
Reviewed-by: Slava Egorov <vegorov@google.com>
2021-09-09 17:20:11 +00:00
Albert Mañosa 67ff459606 fix: typo in Object.hash equality operator docs
Fix doc comments regarding equality operators in the newly added `Object.hash` and `Object.hashAll` methods.

Closes https://github.com/dart-lang/sdk/pull/47167
https://github.com/dart-lang/sdk/pull/47167

GitOrigin-RevId: 4e168df4b4e4ad932e12d8a90f73d724d830a9e3
Change-Id: I4b3902cbece98ee31d977882196f0c8ffc210694
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212868
Reviewed-by: Kevin Moore <kevmoo@google.com>
Commit-Queue: Kevin Moore <kevmoo@google.com>
2021-09-09 16:40:33 +00:00
Konstantin Shcheglov a900531934 Don't read files in _isPackageReference() during MoveFileRefactoringImpl.
We regularly get FileSystemException(s) like:
at _PhysicalFile.readAsStringSync (physical_file_system.dart:184)
at _OverlayFile.readAsStringSync (overlay_file_system.dart:206)
at FileSource.contentsFromFile (source_resource.dart:68)
at FileSource.contents (source_resource.dart:55)
at MoveFileRefactoringImpl._isPackageReference (move_file.dart:183)

So, instead we could use already recorded source content from which
the element model was built.

Alternatively we could record different kinds of references into
the index, e.g. IS_REFERENCED_BY_PACKAGE_URI or IS_REFERENCED_BY.

Change-Id: Ic4aa839f706f37c9df2504f866dfca7c7581c347
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212860
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2021-09-09 15:32:03 +00:00
Konstantin Shcheglov 61ed30ac75 Issue 47162. Fix INVALID_IMPLEMENTATION_OVERRIDE when a generic class with a generic method with a covariant parameter.
Bug: https://github.com/dart-lang/sdk/issues/47162
Change-Id: Id04e26a168977516262e40707a97702907b11bb0
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212866
Reviewed-by: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2021-09-09 15:28:53 +00:00
Lasse R.H. Nielsen f7e4886ad2 Make dds package not use ?. for a static call.
This should have been a warning since null safety
(or arguably since 2.0), but analyzer and compilers
didn't display the warning.

Prepare the package for such usage now being enforced and a warning
or even an error.

Change-Id: I73a852b88dabcaa1396aeec08f33856668e31fe9
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212830
Commit-Queue: Lasse R.H. Nielsen <lrn@google.com>
Reviewed-by: Danny Tuppeny <danny@tuppeny.com>
Reviewed-by: Ben Konyi <bkonyi@google.com>
2021-09-09 15:24:01 +00:00
Bruno Leroux ffe3ee691c Call _profileData.finishRequest after request finalisation
Bug : request headers were not captured because finishRequest was
called to early (before headers was fully initialised)
Fixes #47115

TEST=pkg/vm_service/test/get_http_profile_test.dart

Change-Id: I544101c6f37d20e2ddfe7086698c0925f8f5bd09
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212561
Reviewed-by: Ben Konyi <bkonyi@google.com>
Commit-Queue: Ben Konyi <bkonyi@google.com>
2021-09-09 14:16:21 +00:00
Lasse R.H. Nielsen 39a165647a Add compareByIndex helper function to Enum.
Fixes https://github.com/dart-lang/language/issues/1836

Bug: https://github.com/dart-lang/language/issues/1836
Change-Id: I43ef26403a379c795a0bdcdeb470b4818ffb721e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212573
Commit-Queue: Lasse R.H. Nielsen <lrn@google.com>
Reviewed-by: Nate Bosch <nbosch@google.com>
2021-09-09 12:02:15 +00:00
Sam Rawlins e995cb5f7c analyzer: parse prefixed class constructor tearoff with no type args
Change-Id: I5f19dd9592f83820100e0ac498522245cac16dc4
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212700
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Samuel Rawlins <srawlins@google.com>
2021-09-09 07:04:34 +00:00
asiva 2785fe9996 [VM/Runtime] Check for valid values specified for old_gen_heap_size and
new_gen_semi_max_size

TEST=new unit test

Change-Id: I3dd985baf28c1e876c128252c15b8566d22b170d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212267
Commit-Queue: Siva Annamalai <asiva@google.com>
Reviewed-by: Ryan Macnak <rmacnak@google.com>
2021-09-09 02:39:03 +00:00
Stephen Adams e44b653283 [dart2js] format and modernize resolution/
Change-Id: I8f0366bde7b0588055c26642bf7356e39b875e25
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212542
Commit-Queue: Stephen Adams <sra@google.com>
Reviewed-by: Mayank Patke <fishythefish@google.com>
2021-09-09 02:20:12 +00:00
Ryan Macnak 2f8e129713 [vm, gc] Make the generational barriers in the runtime multi-thread safe.
TEST=ci
Bug: https://github.com/dart-lang/sdk/issues/46909
Change-Id: I85b1cd2a7fe7aa835b2dc6b6232dee412219f3ce
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212029
Reviewed-by: Siva Annamalai <asiva@google.com>
Commit-Queue: Ryan Macnak <rmacnak@google.com>
2021-09-09 01:13:32 +00:00
Konstantin Shcheglov 42b3e66c92 Roll versions of packages with HintCode.UNNECESSARY_TYPE_CHECK_TRUE fixed.
Change-Id: I9101335302dfac9cd956c6a6f1313502553909e6
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212804
Reviewed-by: Kevin Moore <kevmoo@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2021-09-09 00:38:53 +00:00
Konstantin Shcheglov 33e4a5763d Issue 47056. Support for type parameters in flatten(), simplify.
Bug: https://github.com/dart-lang/sdk/issues/47056
Change-Id: Ifb257a0a41ada95057d1b51b2a679e71851215aa
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212802
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2021-09-09 00:38:45 +00:00
Kevin Moore 9f3b7cf4c6 analysis_server: migrate to Object.hash functions
Update min SDK to 2.14

Change-Id: I370875b550f5c103560e13697329c1443c036a2c
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212880
Auto-Submit: Kevin Moore <kevmoo@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
2021-09-09 00:23:43 +00:00
Ahmed Ashour 928b6443c4 Add a quick fix for ABSTRACT_CLASS_MEMBER
Fixes #46025

Change-Id: I716d620e7c77c09cf27f922069f57466f3df76ec
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212574
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2021-09-08 22:30:12 +00:00
Srujan Gaddam d87a545a6a [dart:html] Update changes in idl_parser location
Simply adds the new location to the sys.path so it can be found
and filters idl files within idl_parser so it doesn't affect
codegen. Also removes a stale comment to finalize the python3
migration.

Change-Id: I31d93fd8de22e38a0e968587149546565f86e3ba
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212630
Reviewed-by: Riley Porter <rileyporter@google.com>
2021-09-08 22:18:37 +00:00
Srujan Gaddam 240374cab1 [dart:html] Update WebCore and remove idl_parser dependency
Removes idl_parser dependency as it's now in WebCore and updates
the revision to point to the latest WebCore revision, which includes
the Python 3 migration and idl_parser migration.

Change-Id: Ie24bad3258c44fcfe8ef98ca4dae8846a323a1b6
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212629
Reviewed-by: Riley Porter <rileyporter@google.com>
2021-09-08 22:18:37 +00:00
Srujan Gaddam f34eef5b91 [dart:html] Migrate python scripts to python 3
Migrates syntax and semantics from python 2.7.

Major changes include:

- filters
- sorting
- print statements
- higher-order functions
- hashing and comparison

and other misc changes. go.sh consistently gives the libraries
in this and the previous commits with these changes.

Change-Id: I66365739887158d8f321015d36e556447da1bcd3
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/211542
Commit-Queue: Srujan Gaddam <srujzs@google.com>
Reviewed-by: Riley Porter <rileyporter@google.com>
2021-09-08 22:10:53 +00:00
pq 8cee82debb constructor tearoff fix support for unnecessary_lambdas
Fixes: https://github.com/dart-lang/sdk/issues/47103

Change-Id: I521461a587b9272503772e9b13999d8e4e688352
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212803
Commit-Queue: Phil Quitslund <pquitslund@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2021-09-08 21:56:02 +00:00
pq e5c659b55f quick fix for unnecessary_constructor_name
Fixes: https://github.com/dart-lang/sdk/issues/47102

Change-Id: Idd8b44379d49f416eb4d671ed95ed5f9433af00c
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212800
Commit-Queue: Phil Quitslund <pquitslund@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2021-09-08 21:39:12 +00:00
Konstantin Shcheglov d2bde7a29d Issue 47041. Fix false positive for call() declaration in a private extension.
Bug: https://github.com/dart-lang/sdk/issues/47041
Change-Id: Ib37c03ad7350c489f6ee0673000705bdc3f1d01c
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212840
Reviewed-by: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2021-09-08 20:26:33 +00:00
Joshua Litt aed53191e7 [dart2js] Add modular analysis logic.
This is an initial step to get the modular analysis in place, it
includes:
 * flag to emit modular data
 * flag to load modular data
 * new modular strategy that uses serialized modular data
 * serialization of part of the modular data
     - currently only impact-builder-data
 * new flag in our modular test suite to play with the new feature. This
   flag is off by default and will not be tested in the bots
   unless we enable it by default or add a test matrix step for it.

(See original https://dart-review.googlesource.com/c/sdk/+/105702)

Change-Id: I951ab68567f907117a1e868aaf673841ae948484
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/210061
Commit-Queue: Joshua Litt <joshualitt@google.com>
Reviewed-by: Mayank Patke <fishythefish@google.com>
Reviewed-by: Sigmund Cherem <sigmund@google.com>
2021-09-08 19:56:03 +00:00
Stephen Adams 101cc8a655 [dart2js] Modernize allocations in common/ and native/
Change-Id: Ia7a521210865edba0c58b40383cbdc7105875ae9
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212541
Reviewed-by: Mayank Patke <fishythefish@google.com>
Commit-Queue: Stephen Adams <sra@google.com>
2021-09-08 19:33:32 +00:00
Stephen Adams 3d9bef762b [dart2js] dart format --fix on elements/
Change-Id: Ib36a81b39ac27160567fd9714380a3e1e8846b0d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212543
Reviewed-by: Mayank Patke <fishythefish@google.com>
Commit-Queue: Stephen Adams <sra@google.com>
2021-09-08 19:33:13 +00:00
Srujan Gaddam 8100b4de02 [dart:html] Fix implements order for classes
Using a set does not guarantee a consistent order from python 3
onwards, so use a OrderedDict to get a consistent order while
removing any duplicates.

Change-Id: I02d9aae2a82fd119f22b3a5e353b9445ffca963b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/211541
Commit-Queue: Srujan Gaddam <srujzs@google.com>
Reviewed-by: Sigmund Cherem <sigmund@google.com>
Reviewed-by: Riley Porter <rileyporter@google.com>
2021-09-08 18:45:02 +00:00
Stephen Adams 813358e6b5 [dart2js] Fix GenericInstantiation.hashCode
Change-Id: Ia63034f7361d5ba7b227322d588e5afba2d0aaf4
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212544
Commit-Queue: Stephen Adams <sra@google.com>
Reviewed-by: Johnni Winther <johnniwinther@google.com>
2021-09-08 17:45:28 +00:00
Ryan Macnak 31a1fd4b6b [vm, gc] Fix a bug handling WeakProperties under the combination of concurrent marking and write-barrier elimination.
The compiler will in certain cases eliminate write barriers and the runtime will compensate by adding certain objects to a deferred marking stack. These objects will be revisited when marking is finalized. There is no header bit indicating an object has already been added to the deferred marking stack. The same object may be seen by markers multiple times: once as part of ordinary marking and several times as part of deferred marking.

When visiting a WeakProperty, if the fate of its key is not yet known, it is placed in a (worker-local) delayed weak properties list, which is a linked list threaded through the WeakProperties themselves. If more than one worker adds the same WeakProperty to its list, or a single worker does so multiple times, the lists will be corrupted. A previous fix (40cd5fc5f6) attempted to avoid this by ensuring only the worker which marked the WeakProperty would add it to a delayed weak properties list, but this can result in no worker adding the WeakProperty if the WeakProperty is allocated marked and added to the deferred marking stack.

This CL changes the processing of the deferred marking stack to treat WeakProperties as strong references. This ensures a WeakProperty will only be added to a delayed weak properties list by the single worker that encounters it during ordinary marking. This is also very similar to what would happen if the write barrier had not been eliminated: the writes into the marked WeakProperty would cause the new key and value to also become marked.

This CL also fixes another bug where when processing the delayed weak properties lists, the worker would try to ask whether a new-space object was marked.

TEST=ci
Bug: https://github.com/dart-lang/sdk/issues/47128
Change-Id: Id9abaeb4dd52538ebc22ac58e48abcb7ed760854
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212612
Commit-Queue: Ryan Macnak <rmacnak@google.com>
Reviewed-by: Slava Egorov <vegorov@google.com>
Reviewed-by: Siva Annamalai <asiva@google.com>
2021-09-08 17:40:19 +00:00
Ryan Macnak f9b7ed74dc [vm] Remove dead library references from the object store.
- dart:_builtin is only available in the standalone embedder, and should have never been referenced by the VM proper.
 - dart:profiler was long ago renamed to dart:developer.

TEST=build
Change-Id: I0743f52efc3331a8500494b2d87f621190566b62
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212680
Commit-Queue: Ryan Macnak <rmacnak@google.com>
Reviewed-by: Ben Konyi <bkonyi@google.com>
Reviewed-by: Siva Annamalai <asiva@google.com>
2021-09-08 16:29:19 +00:00
Ahmed Ashour ff63fdcba8 Add fix for SWITCH_CASE_COMPLETES_NORMALLY
Fixes #46999

Change-Id: I00b7d9fe6fdd2431d90cdee5248ce58473620807
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212283
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2021-09-08 16:22:39 +00:00
Sam Rawlins c0b5d99d82 Do not report BODY_MIGHT_COMPLETE_NORMALLY for setters
Fixes https://github.com/dart-lang/sdk/issues/42303
Change-Id: I4b0f6ac1f446c22eec278b3421a41e4176864e13
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212720
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Samuel Rawlins <srawlins@google.com>
2021-09-08 16:07:13 +00:00
Sam Rawlins 450dc37e6b Remove unnecessary imports from nnbd_migration
Bug: https://github.com/dart-lang/sdk/issues/44569
Change-Id: I847603b5a1debb55b5c78e0d837ebcfa2d133d77
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212607
Auto-Submit: Samuel Rawlins <srawlins@google.com>
Commit-Queue: Paul Berry <paulberry@google.com>
Reviewed-by: Paul Berry <paulberry@google.com>
2021-09-08 14:15:03 +00:00
Paul Berry 706c7e4a58 Revert "Remove explicit bool type hack."
This reverts commit 4a54307a39.

Reason for revert: Broke internal build, golem

Original change's description:
> Remove explicit bool type hack.
>
> During the fix for https://github.com/dart-lang/language/issues/1785,
> an explicit `bool` type was added to the variable `nullable` to ensure
> that it would properly participate in type promotion while the fix was
> still being rolled out.  Now that the fix is in place, this explicit
> type is no longer needed.
>
> TEST=standard trybots
> Change-Id: Ied468b17dafa03075fd54c0df915e0a539420697
> Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212266
> Reviewed-by: Alexander Markov <alexmarkov@google.com>
> Commit-Queue: Paul Berry <paulberry@google.com>

TBR=paulberry@google.com,alexmarkov@google.com

Change-Id: I748060275968e1a87a78e90d3770b17543549f33
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212783
Reviewed-by: Paul Berry <paulberry@google.com>
Commit-Queue: Paul Berry <paulberry@google.com>
2021-09-08 14:07:25 +00:00
Vyacheslav Egorov d8d7af15ce [vm] Migrate away from native 'name' syntax.
As part of deprecating support for native extensions we are also
migrating away from legacy VM-specific `native 'name'` syntax
towards metadata based encoding which does not require any special
syntax.

This CL is a step 1 in migration:

- introduces support for `@pragma('vm:external-name', 'name')`
which serves as a direct replacement for `native 'name'`;
- all core libraries and tests are migrated to use the annotation;

Once this CL lands and rolls we will edit internal and external embedders
to eliminate uses of the native keyword (step 2) and finally remove
support for native keyword across our parsers (step 3).

TEST=ci

Bug: https://github.com/dart-lang/sdk/issues/28791
Change-Id: Id6dea878db82dd4fd81149243c425b5c5dc6df86
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212461
Commit-Queue: Slava Egorov <vegorov@google.com>
Reviewed-by: Lasse R.H. Nielsen <lrn@google.com>
Reviewed-by: Martin Kustermann <kustermann@google.com>
2021-09-08 13:39:34 +00:00
Johnni Winther fbc70d8be6 [cfe] Don't replace concrete stubs with abstract methods in mixin transformation
Closes #46389
Closes #46390

Change-Id: If3446d08d0feaf8f778dc396bbed1ebb1c5c0bc7
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212745
Reviewed-by: Dmitry Stefantsov <dmitryas@google.com>
Commit-Queue: Johnni Winther <johnniwinther@google.com>
2021-09-08 12:43:35 +00:00
Paul Berry 4a54307a39 Remove explicit bool type hack.
During the fix for https://github.com/dart-lang/language/issues/1785,
an explicit `bool` type was added to the variable `nullable` to ensure
that it would properly participate in type promotion while the fix was
still being rolled out.  Now that the fix is in place, this explicit
type is no longer needed.

TEST=standard trybots
Change-Id: Ied468b17dafa03075fd54c0df915e0a539420697
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/212266
Reviewed-by: Alexander Markov <alexmarkov@google.com>
Commit-Queue: Paul Berry <paulberry@google.com>
2021-09-08 12:04:13 +00:00