mirror of
https://github.com/dart-lang/sdk
synced 2024-10-14 14:13:09 +00:00
ef6ce1e88a
Records can be constructed, returned, and field accessed in non-dynamic code. Type checks don't work, so records cannot be added to generic collections like `List<(int,int>)`. - Add runtime for base classes for records of various arities. - Use impacts to collect record static types used. - Create record classes for each record shape. Record classes have extra metadata properties on the prototype. This allows slower, general operations at the root of the hierarchy that can be overridden with specialized operations lower in the hierarchy. Change-Id: Ic1b38a5076c2d05f2ecff0a9ed3255b43645386e Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/278699 Commit-Queue: Stephen Adams <sra@google.com> Reviewed-by: Nate Biggs <natebiggs@google.com> |
||
---|---|---|
.. | ||
lib/synced | ||
test | ||
analysis_options.yaml | ||
OWNERS | ||
pubspec.yaml | ||
README.md |
Package js_shared
:
This code is a compile time dependency of dart2js and DDC. It is imported as
a package:
import by both compilers.
There is an exact copy in the SDK of the libraries in the
pkg/js_shared/lib/synced
sub-directory.
Those libraries are imported as dart:
imports by the dart2js and DDC runtime
libraries.
Important: all code under pkg/js_shared/lib/synced
must be kept in sync with
the runtime (in sdk/lib/_internal/js_shared/lib/synced
) at all times. The
test/in_sync_test.dart
test verifies this.