Minor refactoring to share building the map from argument names to
compiled instructions.
Fixes#47047
Change-Id: I20b8d37673bd4cb18aa8b2091af79e40ec498370
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/223381
Reviewed-by: Mayank Patke <fishythefish@google.com>
Commit-Queue: Stephen Adams <sra@google.com>
This just adds a wrapping step to message generation to generate
Dart strings that are wrapped at (or before) 80 characters.
Change-Id: I55b2e307c73beac567cf15492fcca733e1c61a12
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/223442
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Paul Berry <paulberry@google.com>
Commit-Queue: Samuel Rawlins <srawlins@google.com>
This header is only used by an assert, but the load was not removed by the C++ compiler in release mode. Explicitly exclude the loads with the preprocessor so they only happen in debug mode, and limit the assert reading the backing store's header to non-parallel scavenges only.
TEST=tsan
Bug: https://github.com/dart-lang/sdk/issues/47895
Change-Id: Idbbdb743404d8ee15b0f8e13332c022453de085c
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/223660
Reviewed-by: Alexander Aprelev <aam@google.com>
Commit-Queue: Ryan Macnak <rmacnak@google.com>
This version has reverted a change which was incompatible with google3
during the last roll.
Change-Id: I004cba8695aa8c7ce3d1f96b4f92974db6cec673
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/222360
Auto-Submit: Nate Bosch <nbosch@google.com>
Commit-Queue: Nate Bosch <nbosch@google.com>
Reviewed-by: Leon Senft <leonsenft@google.com>
Commit-Queue: Leon Senft <leonsenft@google.com>
Generating identity hashes from the runtime no longer calls into Dart. On 32-bit systems, generating identity hashes from Dart now does only one runtime transition.
TEST=ci
Bug: https://github.com/dart-lang/sdk/issues/47873
Change-Id: Ib21156cb05706f81744eb4e5ccb644f40aa84c96
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/222326
Reviewed-by: Alexander Markov <alexmarkov@google.com>
Account for TransferableTypedData when receiving messages in
native ports and not crash.
TEST=added new API test
Bug:47686
Change-Id: I2dfad694532f544df3000cd97015089ebb5176fa
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/222031
Reviewed-by: Ryan Macnak <rmacnak@google.com>
Commit-Queue: Siva Annamalai <asiva@google.com>
Roll the version number and constrain the sdk version with this
new roll. Next beta will be 2.16, so use that as the minimum.
Change-Id: I50ac1309255f9553ec2faa21958759e15e7712cc
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/222940
Reviewed-by: Sigmund Cherem <sigmund@google.com>
Commit-Queue: Srujan Gaddam <srujzs@google.com>
Start using constructor tearoffs in libraries that have been migrated to
null safety.
Change-Id: I1a448a42b811c2f278d25a823356ee60a452848f
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/223341
Reviewed-by: Anna Gringauze <annagrin@google.com>
Commit-Queue: Nicholas Shahan <nshahan@google.com>
Redirecting factories are never hit in source coverage report because
front-end replaces calls to redirecting factories with calls to their
targets. This change excludes redirecting factories from source
coverage reports.
TEST=vm/cc/SourceReport_Regress95008_RedirectingFactory
Fixes https://github.com/flutter/flutter/issues/95008
Change-Id: I0f6af291f7ee0c042521c92063092f990426b995
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/223600
Reviewed-by: Liam Appelbe <liama@google.com>
Commit-Queue: Alexander Markov <alexmarkov@google.com>
Reading a library as an entry point, which is done for entry points
of script compilation, for files in modular compilation, _or_ for
invalidated files in incremental compilation, doesn't provide an
accessor library which is otherwise used to check if loading of
platform private libraries is allowed.
A recent change to how the entry point of a script compilation is
tracked, exposed a throwing path, added to ensure that reading libraries
through imports, exports and parts provided the accessing library. This
check should have been an assert, since its omission has no immediate
negative effect, and by reordering the code, could even behandled with
null safety.
The exposed throwing path has been seen to cause crashes in incremental
compilation: https://github.com/flutter/flutter/issues/95014
This change removes the throwing path and therefore avoids the crashes
seen in incremental compilation.
Change-Id: Ibff76dae727204b727389bb9f80c5c733855242c
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/223420
Reviewed-by: Chloe Stefantsova <cstefantsova@google.com>
Commit-Queue: Johnni Winther <johnniwinther@google.com>
Change-Id: Ied7cdc131541711f80cd1d053660438bfcdc55ce
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/223421
Reviewed-by: Alexander Thomas <athom@google.com>
Commit-Queue: Alexander Thomas <athom@google.com>
So, we don't need ExtensionCache anymore.
This fixes the issue with importing a library from lib/src sometimes.
Bug: https://github.com/dart-lang/sdk/issues/47842
Change-Id: I9a28fb2e1e14ab96a58c3ef72daa87562f1bccd6
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/223441
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
+ handle them through the origin library.
This prepares for supporting multiple patch libraries for the same
library.
Change-Id: Ib4934fd2f2c7f743fa342dae86002ac72d57f9a3
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/222304
Reviewed-by: Chloe Stefantsova <cstefantsova@google.com>
These are needed to support generating forwarding constructors in
mixin applications.
Change-Id: I71813295c3445752cbdbe1ba5245b2ba9057c622
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/223060
Reviewed-by: Chloe Stefantsova <cstefantsova@google.com>
We still use `ExtensionCache` to fix members.
I will try to change this next.
Change-Id: I047250b0fc9187673fcc88e80b1d40fc421db475
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/222542
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
Now that JavaScriptObject is the new parent class of the old
JavaScriptObject (now called LegacyJavaScriptObject), web classes
should extend it instead.
Change-Id: I94613177bd073e131bff70d8e00e4e6ae8e8949f
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216275
Reviewed-by: Sigmund Cherem <sigmund@google.com>
Reviewed-by: Riley Porter <rileyporter@google.com>
Commit-Queue: Srujan Gaddam <srujzs@google.com>
Tests to make sure static interop classes are erased as expected,
can be used as expected, and that the typing/subtyping relationships
are correct.
Change-Id: Icd68b63f4b7b7f06ec1490a411e31792e9e1fea8
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216274
Reviewed-by: Sigmund Cherem <sigmund@google.com>
Reviewed-by: Riley Porter <rileyporter@google.com>
Pre-null safety, `Object` procedures are synthesized in classes.
Since these are instance members, this triggers static interop
errors on all classes, so they need to be filtered out.
Change-Id: I5c66da6277c4d93c19cce930d54e933d842ecf85
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216560
Reviewed-by: Sigmund Cherem <sigmund@google.com>
Reviewed-by: Riley Porter <rileyporter@google.com>
With erasure and small changes to RTI, these can be uncommented.
Change-Id: I3fb29cd9984b60a8fde74eb47849436b6cb6dd44
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216273
Reviewed-by: Sigmund Cherem <sigmund@google.com>
Reviewed-by: Riley Porter <rileyporter@google.com>
Part 2 of the renaming to create the new parent type. Also modifies
some existing tests to reflect the change in name and function of
JavaScriptObject.
Change-Id: If37f34dd8477b7fc1fe459d3225ecf2537fb9f1a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/217156
Reviewed-by: Sigmund Cherem <sigmund@google.com>
Reviewed-by: Mayank Patke <fishythefish@google.com>
Changes in type hierarchy will have JavaScriptObject as the new
parent class of interop and native types instead. Also modifies
js_interop_constructor_name tests to reflect addition of static
interop.
Change-Id: I74957ca89aea1726a01e0677548fbb3c5c981323
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/215949
Reviewed-by: Sigmund Cherem <sigmund@google.com>
Reviewed-by: Mayank Patke <fishythefish@google.com>
Closes https://github.com/dart-lang/sdk/issues/47324
Erases static interop class types in favor of `BaseJavaScriptObject`.
Types are erased everywhere except for constructors, whose invocations
are instead wrapped with a cast. Constructor type erasure is avoided
to ensure the AST is still type-valid. Factories with bodies have
static stubs added instead, and tests are added for this change.
Change-Id: I7231aaaf32d22bc6261adb672a602e8a9e6c86a9
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/215948
Reviewed-by: Sigmund Cherem <sigmund@google.com>
Reviewed-by: Riley Porter <rileyporter@google.com>