Commit graph

82242 commits

Author SHA1 Message Date
Devon Carew 1e1c730140 [api docs] speed up API doc validation
Change-Id: Ieb4f8f8a406f28afb6e43c10727aa74a194e9b8c
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216686
Commit-Queue: Devon Carew <devoncarew@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
2021-10-13 22:53:07 +00:00
Paul Berry fe0e921728 Test CompileTimeErrorCode.WRONG_NUMBER_OF_TYPE_ARGUMENTS_CONSTRUCTOR with .new.
Change-Id: If4bb810904581527e8e1dd806a1c5db319bc8566
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216720
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Samuel Rawlins <srawlins@google.com>
Commit-Queue: Paul Berry <paulberry@google.com>
2021-10-13 22:06:07 +00:00
Brian Wilkerson d6936a5749 Make the use of Example and Examples more consistent
I think the headings are now 'correct' in the sense that they are
singular when there's a single example and plural when there is more
than one.

In the process I noticed that we have a similar problem with 'Common
fixes' in that sometimes there's one fix and sometimes multiple. I
don't think it would read well to say 'Common fix', so I'm disinclined
to change those, but it makes me wonder whether I should have just
used 'Examples' everywhere.

Change-Id: Idbfc3354b52cf1da677db51f4c626bb3269465b8
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/215983
Commit-Queue: Kathy Walrath <kathyw@google.com>
Reviewed-by: Kathy Walrath <kathyw@google.com>
2021-10-13 21:41:17 +00:00
Ryan Macnak b4b7b8f116 [build] Add support for building for Fuchsia from Mac.
TEST=./tools/build.py --os=fuchsia --mode=all runtime create_sdk
Change-Id: I6b15d1cc174b84d900d526730e5f58d64d2596cb
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216540
Commit-Queue: Ryan Macnak <rmacnak@google.com>
Reviewed-by: Liam Appelbe <liama@google.com>
2021-10-13 21:14:56 +00:00
Konstantin Shcheglov 238a72a321 Support for experimental fields in analyzer_plugin common_types_spec.html
Change-Id: Id91cf321f4f99e29fd3f2be672335ae5c349f195
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216683
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2021-10-13 20:16:26 +00:00
Alexander Aprelev 3b1d941ae8 [io/sendmessage] Update CHANGELOG with note about newly added RawSocket sendMessage/receiveMessage
Bug: https://github.com/dart-lang/sdk/issues/46328
Change-Id: Ibab66e04c61647968cc8531cfc7533f3a8d7daad
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216700
Commit-Queue: Alexander Aprelev <aam@google.com>
Reviewed-by: Siva Annamalai <asiva@google.com>
2021-10-13 18:24:26 +00:00
Konstantin Shcheglov aa27de8501 Tweaks for BundleReader.
Change-Id: If3823a4eb79b399c336c125c2a9673cc121226b5
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216701
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2021-10-13 17:57:46 +00:00
Ryan Macnak 2997bc12af [build] Update Clang and GN.
TEST=ci
Change-Id: I199bdd75d57dbec0b64ddbb7a1b6c71845f4660d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216581
Reviewed-by: Liam Appelbe <liama@google.com>
Commit-Queue: Ryan Macnak <rmacnak@google.com>
2021-10-13 17:54:16 +00:00
Siva Annamalai b6c659ae8f Revert "[ VM / Profiler ] Update MacOS thread interrupter to use Mach APIs instead of SIGPROF"
This reverts commit 4daa257b32.

Reason for revert: Flutter Engine build breaks on iOS builds (32 bit)

Original change's description:
> [ VM / Profiler ] Update MacOS thread interrupter to use Mach APIs instead of SIGPROF
>
> Enabling the CPU profiler on OSX/iOS with a lldb connection would cause
> applications to slow to a crawl due to lldb performing checks on each
> SIGPROF. This change replaces the SIGPROF based thread interrupter for
> MacOS with one based on the Mach Thread APIs.
>
> Fixes https://github.com/dart-lang/sdk/issues/47139
>
> TEST=Manual testing, CQ
>
> Change-Id: Iedfd73a83f92d51e01b98bfa281440c7d1ba9e08
> Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216220
> Commit-Queue: Ben Konyi <bkonyi@google.com>
> Reviewed-by: Ryan Macnak <rmacnak@google.com>

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

Change-Id: I4edf1b73d8f90934fff92971fac8ef7b0f165971
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216682
Reviewed-by: Siva Annamalai <asiva@google.com>
Commit-Queue: Siva Annamalai <asiva@google.com>
2021-10-13 17:19:30 +00:00
Ryan Macnak 868b6a898c [vm, gc] Use relaxed loads when reading the header of an ephemeron's key.
The ephemeron and its key may be processed by different workers, so there is a race when accessing the key's header. This race is harmless: if the key becomes a survivor, it will trigger another round of ephemeron processing.

TEST=tsan, splay_ephemeron_test
Bug: https://github.com/dart-lang/sdk/issues/47412
Change-Id: I20339c2215f2d37ad8b9687aebe62492b36a8a61
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216340
Reviewed-by: Liam Appelbe <liama@google.com>
Commit-Queue: Ryan Macnak <rmacnak@google.com>
2021-10-13 16:56:06 +00:00
Ryan Macnak 81c87d25eb [build] Update Fuchsia SDK.
TEST=ci
Change-Id: I5a2c18c91aee364b5a5f81e1fed60cf84cdaeca6
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216561
Reviewed-by: Liam Appelbe <liama@google.com>
Commit-Queue: Ryan Macnak <rmacnak@google.com>
2021-10-13 16:47:26 +00:00
Devon Carew 2a273a60ec [api docs] make dart:ffi doc samples analysis clean
Change-Id: I70caf6543f231905dd45b78816f2fc8a4e7f4ea3
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216600
Reviewed-by: Daco Harkes <dacoharkes@google.com>
Commit-Queue: Devon Carew <devoncarew@google.com>
2021-10-13 16:32:14 +00:00
Paul Berry a5714b1290 Fix error messages that don't properly name members.
The error messages for INVALID_NON_VIRTUAL_ANNOTATION and
INVALID_SEALED_ANNOTATION appeared to reference the name of the
erroneously declared member, with messages like "The member '{0}'
can't be '@nonVirtual' because it isn't a concrete instance member.",
however the actual text that was substituted into the error message
wasn't the name of the member, but rather the name of the element
declaring the annotation.  So the error message would always be "The
member 'nonVirtual' can't be '@nonVirtual' because it isn't a concrete
instance member.", which was unhelpful and confusing.

Rather than fix the code to come up with the correct name of the
member (which would have been challenging, because the target of the
annotation could be an extension without a name, and wouldn't have
been that useful anyway, since the error location points to the
member), I've simply rephrased the error messages so that they don't
name the member in question.

Change-Id: I34f74e04607e16211b357429820c0336e0a03059
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216563
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Paul Berry <paulberry@google.com>
2021-10-13 16:13:16 +00:00
Michael Thomsen 914f100be4 Clarify that all of dart:isolate is native only
Change-Id: I7ab2ba3db7828d152c9b3a521389a2e04b0c644f
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216660
Reviewed-by: Martin Kustermann <kustermann@google.com>
Commit-Queue: Michael Thomsen <mit@google.com>
2021-10-13 15:03:26 +00:00
Sam Rawlins cebf84d729 Allow any type parameter as a potentially const expression
Bug: https://github.com/dart-lang/sdk/issues/46020

Fixes language/const/instantiated_function_constant_test

Change-Id: I7b9a92a7abca213919d0850dd68c5b2d3d4857f5
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216601
Commit-Queue: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
2021-10-13 14:47:36 +00:00
Sam Rawlins 20da76f9f8 Update parser to allow unnamed constructor reference in comment reference
Code like `/// See also [List.new].` will be accepted as a valid comment
reference.

Test in front_end, analyzer, analysis_server.

Remove TODOs in analyzer for reporting a reference to an element whose
library is not the library in which the comment is found.

Bug: https://github.com/dart-lang/sdk/issues/47446
Change-Id: Ifa19278f92ac003082b62b121c66f0559c0152e8
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216583
Commit-Queue: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Jens Johansen <jensj@google.com>
2021-10-13 14:09:26 +00:00
Chloe Stefantsova 24fb189bc3 [cfe] Don't unalias constructor calls prematurely
Closes https://github.com/dart-lang/sdk/issues/47339.

Bug: https://github.com/dart-lang/sdk/issues/47339
Change-Id: I5fa7bf330676c92b5a074478319d1d537d1a0e9f
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216185
Reviewed-by: Johnni Winther <johnniwinther@google.com>
Commit-Queue: Chloe Stefantsova <dmitryas@google.com>
2021-10-13 13:33:36 +00:00
Paul Berry a7315f1b0f Prevent nulls from slipping into some error messages.
For CompileTimeErrorCode.UNDEFINED_METHOD, it was possible that the
undefined method reference might appear inside an unnamed extension
declaration.  This was fixed by changing the error message to refer to
the extended type rather than the extension name.

For HintCode.INVALID_VISIBLE_FOR_OVERRIDING_ANNOTATION and
CompileTimeErrorCode.EXTENSION_CONFLICTING_STATIC_AND_INSTANCE, we
just allow the name to be `<unnamed>` when the declaration in question
is an unnamed extension.

For AnalysisOptionsWarningCode.UNRECOGNIZED_ERROR_CODE and
AnalysisOptionsWarningCode.UNSUPPORTED_OPTION_WITH_LEGAL_VALUES, it's
actually ok for `null` to show up in the error message, because it can
only happen if the user has a literal `null` in their options file.
However, the way we want this to work is by passing the string `null`
as an argument to the error message (rather than the `null` value);
this will allow us to make message arguments non-nullable in a
follow-up CL.

Change-Id: I67138f314e6234d860c01d083d7c08a1a3ef11ed
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216460
Reviewed-by: Samuel Rawlins <srawlins@google.com>
Commit-Queue: Paul Berry <paulberry@google.com>
2021-10-13 13:21:15 +00:00
Vyacheslav Egorov 36caf54631 [vm/aot] Allow dropping dyn:-forwarder targets
Currently there is a strong link between dyn:-forwarder and
its target (through Function::data_ field). This link causes us
to retain some Function objects even if they are otherwise
considered dropped.

In reality this link is only ever used during compilation
or when accessing script information for the dyn:-forwarder.

As such when generating snapshots in DWARF stack traces mode
we should be able to consider this connection weak
and allow dropped Function objects to be truly discarded from
the snapshot.

This change puts WSR in between dyn:-forwarder and its target
when we know that target is not going to be retained.

We also clean how forwarding target represented to avoid
unnecessary indirection through a one-element array.

TEST=ci

Cq-Include-Trybots: luci.dart.try:vm-kernel-precomp-dwarf-linux-product-x64-try,vm-kernel-precomp-linux-debug-x64-try,vm-kernel-precomp-linux-release-x64-try
Change-Id: I4f0ec822ff15f78c72ff55a87d9dc52abd466cb3
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216040
Commit-Queue: Slava Egorov <vegorov@google.com>
Reviewed-by: Alexander Markov <alexmarkov@google.com>
2021-10-13 11:35:26 +00:00
Johnni Winther 56490f9776 [cfe] Add Procedure.signatureType
The added field holds the interface signature type for a Procedure when
this is different from the class signature type (implied by the function
parameters and return type). This is needed for forwarding semi stubs
when its declared type is different from the called super member.

Closes https://github.com/dart-lang/sdk/issues/47072

TEST=pkg/front_end/testcases/general/implement_semi_stub.dart and more

Change-Id: I4a7cdc9d564fb0a59e7b06e83646b5410d8d82f5
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216420
Commit-Queue: Johnni Winther <johnniwinther@google.com>
Reviewed-by: Chloe Stefantsova <dmitryas@google.com>
2021-10-13 11:31:16 +00:00
Alexander Thomas d146c8e0e9 [release] Add release notes for 2.14.4
Change-Id: Ib27a83ae929dcb9514439df791d6d5028eb63a35
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216620
Reviewed-by: Michael Thomsen <mit@google.com>
2021-10-13 09:02:30 +00:00
Sam Rawlins 44ecf4524d DAS: Remove unused createAnalysisOptionsFile
Change-Id: I03a452d6b93d2d25e1da9cabc1c120ebe468562d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216501
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Samuel Rawlins <srawlins@google.com>
2021-10-13 01:52:25 +00:00
Konstantin Shcheglov b28a193800 Increment DATA_VERSION.
Change-Id: I0cef3b80292868a9ff335e2c756317b74c102841
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216602
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
2021-10-13 00:21:40 +00:00
Konstantin Shcheglov 639350b13e Put informativeBytes into UnlinkedUnit.
Change-Id: I6f514d9032372cf0ec7dc00e97b79c5af021930c
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216520
Reviewed-by: Keerti Parthasarathy <keertip@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2021-10-12 23:34:05 +00:00
Konstantin Shcheglov 1cb40275a1 Remove a hack for inferred top-level variable types in LibraryAnalyzer.
We don't need it anymore, a few years as probably.

Change-Id: Ieccb8fa303d8bc4595268ba6bde2b5da8bdc2731
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216541
Reviewed-by: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2021-10-12 22:54:15 +00:00
Konstantin Shcheglov f83b1dfb9f Remove unused IDL declarations.
Change-Id: Ib753bdd4b9c0464f0a0ed52f11aa473644d89ac5
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216480
Reviewed-by: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2021-10-12 22:34:35 +00:00
Konstantin Shcheglov b0ede2b96b Don't copy AnalysisDriverUnlinkedUnit sets.
Change-Id: I610ab071504b1b61b42d919bab206e3c297990f8
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216500
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2021-10-12 22:33:25 +00:00
Ben Konyi 4daa257b32 [ VM / Profiler ] Update MacOS thread interrupter to use Mach APIs instead of SIGPROF
Enabling the CPU profiler on OSX/iOS with a lldb connection would cause
applications to slow to a crawl due to lldb performing checks on each
SIGPROF. This change replaces the SIGPROF based thread interrupter for
MacOS with one based on the Mach Thread APIs.

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

TEST=Manual testing, CQ

Change-Id: Iedfd73a83f92d51e01b98bfa281440c7d1ba9e08
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216220
Commit-Queue: Ben Konyi <bkonyi@google.com>
Reviewed-by: Ryan Macnak <rmacnak@google.com>
2021-10-12 21:43:45 +00:00
Ryan Macnak 62a5289e7a [observatory] Include "uncollected garbage" and "free" when diffing heap snapshots.
TEST=examine "heap snapshot" in Observatory
Change-Id: I13436496a7dadcbd96c85a5bf7b7c0a0d647a4d4
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/215987
Reviewed-by: Ben Konyi <bkonyi@google.com>
Commit-Queue: Ryan Macnak <rmacnak@google.com>
2021-10-12 21:34:05 +00:00
Sam Rawlins 957fe1a0f6 Consolidate const InstanceCreationExpression tests
Evaluation of a constructor's initializers (field initializers, assert
initializers, and super initializer) are all so much complexity separate
from evaluating a simpler const object that they deserve their own test
classes.

* Move all tests using assert initializers from very old
  non_error_resolver.test and from constant.dart to
  InstanceCreationEvaluatorTestCases.
* Move many test cases into *TestCases so they are tested in pre- and
  post-null safety.
* Introduce more basic tests for assert initializers.

Bug: Preparation for https://github.com/dart-lang/sdk/issues/46081
Change-Id: Ie3e21d2457b1ba34667f85a0f5e3ef0e558f5cb3
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216380
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Samuel Rawlins <srawlins@google.com>
2021-10-12 21:08:35 +00:00
Konstantin Shcheglov 1edcd482f3 Use Uint8List in ResourceProvider(s).
Change-Id: I0f0d3af1d196117c3e722013eb708af27130269e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216278
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Samuel Rawlins <srawlins@google.com>
2021-10-12 21:04:13 +00:00
Konstantin Shcheglov 5e8c454665 Store CiderUnlinkedUnit in binary format.
Change-Id: I36f9a2de22a82d762480254a589d80268179be44
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216440
Reviewed-by: Keerti Parthasarathy <keertip@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2021-10-12 21:00:45 +00:00
Konstantin Shcheglov 16e3734b14 Prepare to publish analyzer 2.6.0 and _fe_analyzer_shared 29.0.0
Change-Id: Ia7aa32d010597251dfc133fe6eac40ce149a48a5
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216360
Reviewed-by: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2021-10-12 20:59:45 +00:00
Nate Bosch f9c68a5679 Replace a bunch of references to .packages
Most of these arguments are flowing through to a `--packages` argument
which allows passing the `package_config.json` file. In the long term we
should remove the `.packages` file entirely.

TEST=None, the change should have no visible impact.

Change-Id: I60a8b175d5e217a85588bbcb91cc5095514066b4
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/211503
Auto-Submit: Nate Bosch <nbosch@google.com>
Commit-Queue: Nate Bosch <nbosch@google.com>
Reviewed-by: Kevin Moore <kevmoo@google.com>
Reviewed-by: Lasse R.H. Nielsen <lrn@google.com>
2021-10-12 20:16:15 +00:00
Konstantin Shcheglov baecc6fccc For for LateInitializationError in Cider topLevelDeclarations.
Change-Id: I1e52d251a8e63a05304da701d6157986d25d9f21
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216400
Reviewed-by: Keerti Parthasarathy <keertip@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2021-10-12 19:57:45 +00:00
Konstantin Shcheglov 14428eda69 Return AnalysisDriverUnlinkedUnit, don't read it if just created.
Change-Id: If2977a23efc337f6d33d6f8490a6cd5cfac96be4
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216321
Reviewed-by: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2021-10-12 19:16:50 +00:00
Ryan Macnak 1d70168786 [build] Fix arm and arm64 gcc builds.
TEST=./tools/build.py --no-goma --no-clang --arch=arm,arm64 runtime
Bug: https://github.com/dart-lang/sdk/issues/47330
Change-Id: I32cea56e3ad64200a7057cc6a381bc6d9656ec7b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/215984
Commit-Queue: Ryan Macnak <rmacnak@google.com>
Reviewed-by: Alexander Aprelev <aam@google.com>
2021-10-12 18:49:52 +00:00
Michael Thomsen 523a84d4cc Proof reading on Isolate.exit() docs
Change-Id: I62b8dc76afa2ebcd0be395bd77b33156978e0dd8
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216291
Reviewed-by: Alexander Aprelev <aam@google.com>
Commit-Queue: Michael Thomsen <mit@google.com>
2021-10-12 18:19:40 +00:00
Ryan Macnak b21302a7b7 [observatory] Reset the selected diff when selecting new snapshots in the process memory view.
TEST=examine "process memory" in Observatory
Change-Id: I26abee984713067effff95fadb95e5eb1092b74f
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/215986
Reviewed-by: Ben Konyi <bkonyi@google.com>
Commit-Queue: Ryan Macnak <rmacnak@google.com>
2021-10-12 18:14:20 +00:00
Alexander Markov 4b04219d94 [vm] Fix intrinsified Type.operator== for generic types with not finalized classes
UntaggedClass::host_type_arguments_field_offset_in_words_ is initialized
when class is finalized. When comparing generic types for the class
which was not finalized, we cannot rely on the value of that field.

Intrinsified Type.operator== has been using host_type_arguments_field_offset_in_words_
to check if the class is generic, and has been treating classes which
are not finalized as non-generic. This has been causing the wrong
result for generic types which are different only in type arguments.

This change fixes Type.operator== intrinsics to check if
type arguments match even if class was not finalized.

Also, EquivalentClassIds helper was revised to take 3 labels
explicitly for all possible outcomes (instead of 2 labels and
a fall-through).

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

Change-Id: I3f49114644d44808c668df7cbb8a702cd42b3673
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216270
Reviewed-by: Tess Strickland <sstrickl@google.com>
Commit-Queue: Alexander Markov <alexmarkov@google.com>
2021-10-12 17:03:00 +00:00
Paul Berry f88b5d11d1 Avoid redundant quoting in errors that refer to URIs.
Previously, the compile time errors EXPORT_OF_NON_LIBRARY,
EXPORT_INTERNAL_LIBRARY, and IMPORT_OF_NON_LIBRARY would redundantly
quote their URIs (e.g. an EXPORT_OF_NON_LIBRARY error message might
say "The exported library ''part.dart'' can't have a part-of
directive.").  This change avoids the extra quoting by using the
string value of the URI as an argument to the error rather than the
AST node.

Change-Id: I64f250dcf15f638cfe4a3ade23bb2cd2c710a0d5
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216300
Commit-Queue: Paul Berry <paulberry@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2021-10-12 17:01:40 +00:00
Sam Rawlins 1801969aa9 Add ImplicitCallReference AST node subtype and visit methods
Bug: https://github.com/dart-lang/sdk/issues/47443

Change-Id: I70f9fda3256f963b805ba379d79f706010f0c2fa
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216269
Commit-Queue: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2021-10-12 16:14:40 +00:00
Konstantin Shcheglov aeb6767650 Issue 47407. Move USE_OF_NATIVE_EXTENSION to CompileTimeErrorCode.
Bug: https://github.com/dart-lang/sdk/issues/47407
Change-Id: I342579ecac391ffc013cf7f05e81584996a7eea8
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216268
Reviewed-by: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2021-10-12 16:13:30 +00:00
Johnni Winther a6fe06af36 Fix language/const/constant_type_variable_error_test
Change-Id: I8f2c65485d694db1a831f6778e3b6a03c280c638
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216288
Reviewed-by: Erik Ernst <eernst@google.com>
Commit-Queue: Johnni Winther <johnniwinther@google.com>
2021-10-12 16:06:09 +00:00
Konstantin Shcheglov 9e296e1553 Use Uint8List in ByteStore.
Change-Id: I36530aabc6169a9bf05cd212da5fe604f45d4cee
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216277
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2021-10-12 15:33:10 +00:00
Danny Tuppeny 1bfa0bb8dd [dds] Wrap DAP dart.log message in an object for future extensibility
Change-Id: Ifbff825751f7456645b28f23684447e1271e4ece
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216290
Reviewed-by: Ben Konyi <bkonyi@google.com>
Commit-Queue: Ben Konyi <bkonyi@google.com>
2021-10-12 15:17:00 +00:00
Sam Rawlins 05298343b5 Allow type variables in constant evaluation, if ctor-tearoffs are enabled.
This requires passing the runtime type arguments into the
InstanceCreationEvaluator, so that it can store them in a lexical scope
map.

Bug: https://github.com/dart-lang/sdk/issues/47302
Change-Id: I6b9d660f20b981d26810f29858784c034cc8abfd
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/215960
Commit-Queue: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
2021-10-12 15:05:29 +00:00
Brian Wilkerson 396e58e0f2 Improve test that error codes were generated
It appears that invoking exit with a value other than either zero (0) or
254 causes the test infrastructure to interpret the failure as a failure
in the infrastructure, turning the bot purple rather than red. Thowing
an exception is interpreted correctly, so I believe that this change will
cause a need to regenerate to show up as a red bot.

Change-Id: I01e9fc2bfe09fac3da2a9aade69fabf3abd17179
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216260
Reviewed-by: Paul Berry <paulberry@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2021-10-12 14:47:20 +00:00
Sigurd Meldgaard b2ea872861 Bump usage to ac53249e5230a77624f46c07c2ed965efcfc0c59
This is a reland of: https://dart-review.googlesource.com/c/sdk/+/213349
Reverted in https://dart-review.googlesource.com/c/sdk/+/213440 due to http://b/199988795

The two failures in that issue has been addressed by "ac53249 Fix timeout" and "117d3a1 Allow sendRaw to send Map<String, dynamic>"


Most of these commits stem from a non-squashed merge.

Changes:
```
> git log --format="%C(auto) %h %s" e0780cd..ac53249
 https://dart.googlesource.com/usage.git/+/ac53249 Fix timeout (#162)
 https://dart.googlesource.com/usage.git/+/117d3a1 Allow sendRaw to send Map<String, dynamic> (#161)
 https://dart.googlesource.com/usage.git/+/016dd30 Prepare release (#160)
 https://dart.googlesource.com/usage.git/+/076c653 Merge pull request #152 from sigurdm/batching
 https://dart.googlesource.com/usage.git/+/1d6b343 Remove debug print
 https://dart.googlesource.com/usage.git/+/c073fb7 Use correct limit for bytes
 https://dart.googlesource.com/usage.git/+/1d89875 Send batch early if full
 https://dart.googlesource.com/usage.git/+/2896a85 Update README.md
 https://dart.googlesource.com/usage.git/+/da20fab Delete travis.sh
 https://dart.googlesource.com/usage.git/+/7c351a3 Merge
 https://dart.googlesource.com/usage.git/+/0424091 Update build.yaml (#159)
 https://dart.googlesource.com/usage.git/+/4f2a050 Use a Duration for batching delay
 https://dart.googlesource.com/usage.git/+/aa3f3ce address review
 https://dart.googlesource.com/usage.git/+/318ebe5 Fix
 https://dart.googlesource.com/usage.git/+/71ddec1 Send remaining hits on waitForLastPing
 https://dart.googlesource.com/usage.git/+/1c895a7 Parametrize client-id in test
 https://dart.googlesource.com/usage.git/+/0ae7733 Fix pubspec
 https://dart.googlesource.com/usage.git/+/2255b3d Merge remote-tracking branch 'origin/master' into batching
 https://dart.googlesource.com/usage.git/+/14d3702 Merge remote-tracking branch 'origin/master' into batching
 https://dart.googlesource.com/usage.git/+/1c3393d Handle batching implicit waiting for a 'batchDelay' future
 https://dart.googlesource.com/usage.git/+/219b764 TODO about size of payloads
 https://dart.googlesource.com/usage.git/+/aaee6d9 Fix AnalyticsMock
 https://dart.googlesource.com/usage.git/+/a8ec5b4 Remove mockito as dep - didn't use it
 https://dart.googlesource.com/usage.git/+/e26fcce Allow batching of hits

```

Diff: https://dart.googlesource.com/usage.git/+/e0780cd8b2f8af69a28dc52678ffe8492da27d06~..ac53249e5230a77624f46c07c2ed965efcfc0c59/
Change-Id: I1284db2a23a3e9ac037d1d2a80627c0caa1e9385
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/216184
Reviewed-by: Jonas Jensen <jonasfj@google.com>
Commit-Queue: Sigurd Meldgaard <sigurdm@google.com>
2021-10-12 13:01:12 +00:00
Irina Arkhipets a3f8a9562a [co19_2] Instantiate-to-bounds tests excluded according to the Issue 46483 evaluation
Change-Id: I26b028a942d3d95c6bf135f983a22d02d31ddb34
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/215541
Reviewed-by: Alexander Thomas <athom@google.com>
Reviewed-by: Erik Ernst <eernst@google.com>
Commit-Queue: Alexander Thomas <athom@google.com>
2021-10-12 11:26:24 +00:00