Nicholas Shahan
624dd76b6f
[ddc] Move FutureOr normalization to its own visitor
...
Will make it easier to reuse the normalization when compiling
with the new runtime type representation.
Change-Id: Ie767a2b676950205b0b50eadac305c29914433f2
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/247420
Reviewed-by: Srujan Gaddam <srujzs@google.com >
Commit-Queue: Nicholas Shahan <nshahan@google.com >
2022-07-01 18:55:50 +00:00
Nicholas Shahan
f3daca2ef6
[ddc] Fix cast when retrieving annotation name
...
Name can be null and cast failures start appearing here when
running with sound null safety.
Issue: https://github.com/dart-lang/sdk/issues/46617
Change-Id: I3d96e80283889915cc28a310a1db940a9c6bcab1
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/250409
Reviewed-by: Mark Zhou <markzipan@google.com >
Commit-Queue: Nicholas Shahan <nshahan@google.com >
2022-07-01 18:29:10 +00:00
Nicholas Shahan
0f2e021da8
[ddc] Fix non-null assertion crash
...
`VariableDeclaration.name` could be null when the variable
was synthetically introduced by the compiler. In this case the
expression compiler can ignore the variable because it's value
doesn't reflect the value of a variable in the original dart
source code.
Add a regression test for the expression compiler that
ensures code that introduces a synthetic variable will not
cause a crash when you stop at a breakpoint.
Fixes: https://github.com/dart-lang/sdk/issues/49373
Change-Id: Ifc5f72ab4e5733ead17a20889c222bcc46921f6b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/250343
Commit-Queue: Nicholas Shahan <nshahan@google.com >
Reviewed-by: Anna Gringauze <annagrin@google.com >
2022-07-01 16:15:53 +00:00
Srujan Gaddam
b372fd4c52
[CFE/pkg:js] Find reference of stub if it already exists
...
Fixes #49301
From https://github.com/dart-lang/sdk/issues/49301#issuecomment-1165536192
Adds referenceFromIndex to outline transformations so that the eraser
can use it to find the reference for the stub if it was already created.
This is needed when the module where the stub exists is invalidated.
Since references in other modules should still be valid, we should
attempt to get that reference.
Change-Id: I5905a002480444aecd57de650cd439bdc34d4eba
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/249729
Reviewed-by: Johnni Winther <johnniwinther@google.com >
Reviewed-by: Joshua Litt <joshualitt@google.com >
2022-06-28 18:36:02 +00:00
Johnni Winther
e18977ed9c
[cfe] Report error for missing concrete super target
...
In response to https://github.com/dart-lang/sdk/issues/47406
The error is currently not reported if the mixin declaration is from
an outline dill.
Change-Id: I94a61d6409d0c238614d9f377b5f324153360bc6
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/249184
Reviewed-by: Sigmund Cherem <sigmund@google.com >
Reviewed-by: Jens Johansen <jensj@google.com >
Commit-Queue: Johnni Winther <johnniwinther@google.com >
2022-06-24 14:04:49 +00:00
Jens Johansen
b4e2012f5b
[CFE] Remove support for .packages file
...
This CL:
* Removed the redirect from .packages to .dart_tool/package_config.json
(whenever such a file existed).
* Removes support for the old format entirely.
* Updates all tests etc that were found.
Fixes https://github.com/dart-lang/sdk/issues/48939
TEST=Existing tests updated.
Change-Id: Iccf711c455ac1885189aa773ca74dd8f55012964
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/248603
Reviewed-by: Michael Thomsen <mit@google.com >
Reviewed-by: Johnni Winther <johnniwinther@google.com >
Reviewed-by: Alexander Markov <alexmarkov@google.com >
Commit-Queue: Jens Johansen <jensj@google.com >
2022-06-24 08:20:39 +00:00
Johnni Winther
391540c889
[cfe] Make (Abstract)Super*.interfaceTarget non-nullable
...
This is a step towards improving the semantics of these nodes.
TEST=existing
Change-Id: I95bdb86790414b38af73e9e932cc228b3c0f1f6e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/249040
Commit-Queue: Johnni Winther <johnniwinther@google.com >
Reviewed-by: Alexander Markov <alexmarkov@google.com >
Reviewed-by: Jens Johansen <jensj@google.com >
Reviewed-by: Joshua Litt <joshualitt@google.com >
2022-06-23 09:16:55 +00:00
Nicholas Shahan
fed11104ee
[ddc] Fix google3 null safety migration break
...
The code path exercised here is used in google3 and expects
a list of preallocated size.
Change-Id: I807603a8bddb1bfead8f3377df4a6252949a8c3e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/249545
Commit-Queue: Nicholas Shahan <nshahan@google.com >
Reviewed-by: Mark Zhou <markzipan@google.com >
2022-06-23 00:07:55 +00:00
Nicholas Shahan
3f104a2ab4
[ddc] Migrate command to null safety
...
Revert small diffs introduced in earlier migrations to avoid an
import of command.dart before it was migrated.
Issue: https://github.com/dart-lang/sdk/issues/46617
Change-Id: Ia728fd727417fd4fdf8c454a0044e096e9de5756
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/248948
Reviewed-by: Anna Gringauze <annagrin@google.com >
Commit-Queue: Nicholas Shahan <nshahan@google.com >
2022-06-22 21:30:16 +00:00
Nicholas Shahan
6366fddf12
[ddc] Migrate expression_compiler to null safety
...
Migrate the test file that is unblocked.
Issue: https://github.com/dart-lang/sdk/issues/46617
Change-Id: I65598f5837115d7dce1c51389bb7c762c1ce451e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/248884
Reviewed-by: Anna Gringauze <annagrin@google.com >
2022-06-22 21:30:16 +00:00
Nicholas Shahan
de90931be4
[ddc] Migrate compiler to null safety
...
Issue: https://github.com/dart-lang/sdk/issues/46617
Change-Id: Id6a5e2e435b22fad4afcb5d06d0a50dc617f4bf3
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/248705
Reviewed-by: Anna Gringauze <annagrin@google.com >
2022-06-22 21:30:16 +00:00
Nicholas Shahan
c52dd252f8
[ddc] Migrate nullable_inference to null safety
...
Also migrate the test file and temporarily inline some path
generation logic to break import of command.dart until it is
migrated.
Issue: https://github.com/dart-lang/sdk/issues/46617
Change-Id: I50c158729346f3e31059241b90008ba861a65422
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/248341
Reviewed-by: Anna Gringauze <annagrin@google.com >
2022-06-22 21:30:16 +00:00
Nicholas Shahan
c53c6890c4
[ddc] Migrate shared_command to null safety
...
Update CFE API for ddc to mirror the nullability of fields in
`CompilerOptions`.
Issue: https://github.com/dart-lang/sdk/issues/46617
Change-Id: I08d8cc2c5bb1dba4823cb3a7e1f4a540fb3bfef5
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/248181
Commit-Queue: Nicholas Shahan <nshahan@google.com >
Reviewed-by: Mark Zhou <markzipan@google.com >
Reviewed-by: Johnni Winther <johnniwinther@google.com >
2022-06-21 23:22:18 +00:00
Srujan Gaddam
459d57c8b8
[package:js] Add static interop stub for outlines
...
Fixes b/235393918
@staticInterop replaces factories with a new named node, a static
method. In order to persist this transformation in modular
compilation, this needs to be done to outlines that can then be
consumed by the source library. In order to allow erasure at the
time of 'performOutlineTransformations', coreTypes is added to that
API.
Change-Id: I90d17fff8bbe143982fcd12cfb06dc3e8d58781a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/247928
Commit-Queue: Srujan Gaddam <srujzs@google.com >
Reviewed-by: Joshua Litt <joshualitt@google.com >
Reviewed-by: Johnni Winther <johnniwinther@google.com >
2022-06-17 19:58:49 +00:00
Ahmed Ashour
85700570f6
Fix typos
...
Fixes #49241
TEST=ci
Change-Id: I6117bf816fc8c4613cce66927f952fef75632725
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/248120
Reviewed-by: Alexander Thomas <athom@google.com >
Reviewed-by: Johnni Winther <johnniwinther@google.com >
Reviewed-by: Ben Konyi <bkonyi@google.com >
Reviewed-by: Nicholas Shahan <nshahan@google.com >
Commit-Queue: Alexander Thomas <athom@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2022-06-15 11:08:28 +00:00
Konstantin Shcheglov
26e4595411
Import dart:typed_data for BytesBuilder instead of dart:io
...
See https://dart-review.googlesource.com/c/sdk/+/248343
Change-Id: Ibfc8db983c271b5e27ba8f03ed7e192e042da1fd
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/248352
Reviewed-by: Nicholas Shahan <nshahan@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2022-06-14 17:36:34 +00:00
Nicholas Shahan
d50097a4ec
[ddc] Break import cycle in shared_command.dart
...
Reduces the number of libraries that must be migrated to null safety
atomically.
Change-Id: I498f2956471be0435558c1b1a4badcba619f15de
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/247521
Reviewed-by: Sigmund Cherem <sigmund@google.com >
Commit-Queue: Nicholas Shahan <nshahan@google.com >
2022-06-09 16:55:45 +00:00
Sigmund Cherem
e808fa1751
[jsinterop] Add static check for JSName of static class members.
...
Static class members could technically be mapped to a name with dots,
but in the early days of JSInterop we thought this was not necessary
since it could also be modeled as a top-level member or by adding
additional classes and exposing the member as a simple name on a deeper
class.
This invariant was assumed by DDC (which crashed if this was not the
case) and ignored by dart2js.
This change adds a static check to ensure both compilers act
consistenlty.
Fixes https://github.com/dart-lang/sdk/issues/27926
Change-Id: I20e59fbb75f0378a58ca88dc3910e079b4eeb7a3
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/247180
Reviewed-by: Riley Porter <rileyporter@google.com >
Commit-Queue: Riley Porter <rileyporter@google.com >
2022-06-03 17:02:26 +00:00
Nicholas Shahan
dcc97874e7
[ddc] Migrate property_model to null safety
...
Issue: https://github.com/dart-lang/sdk/issues/46617
Change-Id: Ie1e557c698452bee7e16b959078db941863d4d99
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/246162
Reviewed-by: Mark Zhou <markzipan@google.com >
Commit-Queue: Nicholas Shahan <nshahan@google.com >
2022-05-27 20:56:00 +00:00
Nicholas Shahan
fe91c0197a
[ddc] Migrate module_builder to null safety
...
Issue: https://github.com/dart-lang/sdk/issues/46617
Change-Id: I977cf87a4461863b39ee52beb5404cb80f1ac3c6
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/245284
Commit-Queue: Nicholas Shahan <nshahan@google.com >
Reviewed-by: Anna Gringauze <annagrin@google.com >
2022-05-27 00:25:59 +00:00
Nicholas Shahan
e948516c21
[ddc] Migrate js_metalet to null safety
...
Issue: https://github.com/dart-lang/sdk/issues/46617
Change-Id: If3e62c17e9d7f6ae033cce8efd7c71caf611c7f7
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/245283
Reviewed-by: Anna Gringauze <annagrin@google.com >
2022-05-27 00:25:59 +00:00
Nicholas Shahan
9510eb90b2
[ddc] Migrate shared_compiler to null safety
...
Issue: https://github.com/dart-lang/sdk/issues/46617
Change-Id: I9798ccaf61360c9dd6baab2e07c5d228eb45cdc4
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/245461
Reviewed-by: Mark Zhou <markzipan@google.com >
2022-05-27 00:25:59 +00:00
Nicholas Shahan
4d9b28dc08
[ddc] Include shared library for new runtime types
...
When compiling the Dart SDK with the `--canary` flag DDC will include
the new shared runtime type library in the compiled SDK.
Change-Id: I7a418033fb7397939aa6f4b7fb84820ead99c3be
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/241690
Commit-Queue: Nicholas Shahan <nshahan@google.com >
Reviewed-by: Sigmund Cherem <sigmund@google.com >
Reviewed-by: Anna Gringauze <annagrin@google.com >
2022-05-25 18:23:29 +00:00
Mark Zhou
21b690a9ce
[ddc] Adding runtime metrics to extra required libs
...
Part of https://dart-review.googlesource.com/c/sdk/+/244261
Change-Id: I09213f7e37d0d2b2e0d25607a0175228d1c36dbf
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/245285
Reviewed-by: Joshua Litt <joshualitt@google.com >
Commit-Queue: Mark Zhou <markzipan@google.com >
2022-05-20 23:33:53 +00:00
Johnni Winther
cb3cac408d
[kernel] Add AbstractSuper* nodes
...
This adds AbstractSuperMethodInvocation, AbstractSuperPropertyGet,
AbstractSuperPropertySet nodes which are to be used for super access
in mixin declaration.
These super accesses do not resolve to their statically bound target
but instead the interface target on the types in the 'on' clauses, and
need to be updated to the statically bound target upon mixin application.
This has lead backends to disregard the interface target provided by
the CFE and instead always compute targets for super accesses.
This change is a step towards creating a clear separation between the
two use cases, enabling a more precise handling of super accesses.
The new nodes are not created yet with this CL.
TEST=existing
Change-Id: I70ea9baf5b4b970b10cc72b7409633d270d57755
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/245168
Reviewed-by: Alexander Markov <alexmarkov@google.com >
Reviewed-by: Nicholas Shahan <nshahan@google.com >
Reviewed-by: Chloe Stefantsova <cstefantsova@google.com >
Commit-Queue: Johnni Winther <johnniwinther@google.com >
2022-05-20 09:50:01 +00:00
Nicholas Shahan
b62b76bfef
[ddc] Migrate type_table to null safety
...
Change-Id: I3e4da0d6031860e8538a6d7e650eff6f7ab76155
Issue: https://github.com/dart-lang/sdk/issues/46617
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/244262
Reviewed-by: Mark Zhou <markzipan@google.com >
Commit-Queue: Nicholas Shahan <nshahan@google.com >
2022-05-13 19:10:06 +00:00
Mark Zhou
143c6df41b
[ddc] Stubbing package:dart2js_runtime_metrics
...
This allows the package to be discoverable across web backends
Change-Id: I7d870a7232543d3b719d47de1424017d7f578434
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/244261
Commit-Queue: Mark Zhou <markzipan@google.com >
Reviewed-by: Nicholas Shahan <nshahan@google.com >
2022-05-11 22:31:45 +00:00
Nicholas Shahan
112cba1957
[ddc] Add flag to use the new runtime type system
...
Currently the flag does nothing. Follow up changes will add support
incrementally.
Add a `--canary` flag to DDC that will enable all features in
development to simplify use in tests and benchmarks.
Issue: https://github.com/dart-lang/sdk/issues/48950
Change-Id: I4878c771bdb4f4c6e8b8cd618737009268b02cbe
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/237602
Commit-Queue: Nicholas Shahan <nshahan@google.com >
Reviewed-by: Sigmund Cherem <sigmund@google.com >
Reviewed-by: Anna Gringauze <annagrin@google.com >
2022-05-10 23:47:04 +00:00
Nicholas Shahan
be6ca10956
[ddc] Migrate module_containers to null safety
...
Change-Id: Idc8e6a13f6b253b4b1030fe0d0b9a272cebbd079
Issue: https://github.com/dart-lang/sdk/issues/48585
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/243843
Commit-Queue: Nicholas Shahan <nshahan@google.com >
Reviewed-by: Mark Zhou <markzipan@google.com >
2022-05-05 20:51:35 +00:00
Nicholas Shahan
651350bc3b
[ddc] Avoid emitting dead branches in conditionals
...
Don't emit dead code branches that are guarded by boolean literals.
Add a single level of simplification for !true -> false, and
!false -> true.
While this might not be very common in code, it does allow for a
useful pattern in the runtime libraries. Branches can be included
into the compiled code or not based on a compile time flag.
Change-Id: Ib90e1e951cea3ef8c75b944635776b292759594a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/243363
Commit-Queue: Nicholas Shahan <nshahan@google.com >
Reviewed-by: Anna Gringauze <annagrin@google.com >
2022-05-03 20:17:44 +00:00
Stephen Adams
c50157e099
Support invoking JS operators through dart:js_util.
...
Some JS functionality is only exposed through operators, such as
implicit type conversions and BigInt arithmetic. Other than requiring
some minor additions for the exponentiation (`**`) operator, supporting
these through `dart:js_util` is trivial.
Change-Id: I010674303e4f99b42d43b73095de69b8ddcdeb47
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/242680
Reviewed-by: Joshua Litt <joshualitt@google.com >
Reviewed-by: Sigmund Cherem <sigmund@google.com >
Commit-Queue: Stephen Adams <sra@google.com >
2022-04-28 21:18:40 +00:00
pq
cdaf885546
no_leading_underscores_for_local_identifiers
...
These will be flagged by the next linter release which updates `non_constant_identifier_names` to flag local functions.
Change-Id: Idf2b91fa3b845d8b921b7eb68b937d19c4ea188e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/242502
Reviewed-by: Srujan Gaddam <srujzs@google.com >
Commit-Queue: Phil Quitslund <pquitslund@google.com >
2022-04-27 00:15:04 +00:00
Mark Zhou
471fcee079
[ddc] Adding support for static setters of const fields
...
Fixes #48717
Change-Id: I45145bc992bb129d54962b1ed9cfebbdbac41f92
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/239730
Reviewed-by: Nicholas Shahan <nshahan@google.com >
Commit-Queue: Mark Zhou <markzipan@google.com >
2022-04-01 23:51:15 +00:00
Nicholas Shahan
f384a42ebb
[ddc] Enforce more lints and cleanup violations
...
These are now enforced in pkg/js_ast so we don't need to worry about
introducing unwanted diffs between the forked versions.
Change-Id: I89efc97f53a433f98e2a06747690ac7a635c388d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/239560
Reviewed-by: Stephen Adams <sra@google.com >
Commit-Queue: Nicholas Shahan <nshahan@google.com >
2022-04-01 19:39:39 +00:00
Nicholas Shahan
ff3e340815
[ddc] Migrate js_names and js_utils to null safety
...
Change-Id: I187c547d9922185dd20db3e773eb4c8fbe7ec0a6
Issue: https://github.com/dart-lang/sdk/issues/46617
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/239544
Reviewed-by: Stephen Adams <sra@google.com >
Commit-Queue: Nicholas Shahan <nshahan@google.com >
2022-04-01 18:40:19 +00:00
Nicholas Shahan
74caf5f7b9
[ddc] Migrate source_map_printer to null safety
...
Change-Id: I89826ba3af91f1392d6291b008b41af94c0072b1
Issue: https://github.com/dart-lang/sdk/issues/46617
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/239585
Reviewed-by: Mark Zhou <markzipan@google.com >
Commit-Queue: Nicholas Shahan <nshahan@google.com >
2022-04-01 18:26:39 +00:00
Nicholas Shahan
e30e017600
[ddc] Add context to the undetermined nullability error
...
When an unexpected "Undetermined Nullability" is encountered the
compiler will throw a message that contains the library being
compiled and the problematic type.
Change-Id: I0d6c3335b8c207b0344354dc4e9a2d7152571b12
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/239722
Reviewed-by: Mark Zhou <markzipan@google.com >
Commit-Queue: Nicholas Shahan <nshahan@google.com >
2022-04-01 00:04:35 +00:00
Mark Zhou
a75656502a
[ddc] Removing enum field optimizations due to enhanced enums supporting static fields.
...
Some enhanced enum fields need to be emitted lazily, as they can potentially reference other static fields.
Also see: https://github.com/dart-lang/sdk/issues/48700
Change-Id: Iaf738fe95de08b96cc438fbe35fabe907af54566
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/239580
Reviewed-by: Nicholas Shahan <nshahan@google.com >
Commit-Queue: Mark Zhou <markzipan@google.com >
2022-03-30 23:48:40 +00:00
Nicholas Shahan
ba4e18b531
[ddc] Remove more diffs with pkg/js_ast
...
- Remove lint ignores and cleanup violations when they are either
in code that doesn't exist in or are already fixed in the pkg/js_ast
version.
- Migrate the builder_test.dart (the small test file).
Issue: https://github.com/dart-lang/sdk/issues/46617
Change-Id: I1083235de93f028e5f338180b97308f52a45f17f
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/239363
Reviewed-by: Stephen Adams <sra@google.com >
Commit-Queue: Nicholas Shahan <nshahan@google.com >
2022-03-30 19:53:30 +00:00
Nicholas Shahan
4193c18160
[ddc] Migrate js_ast libraries to null safety
...
- builder.dart
- template.dart
Change-Id: Ie399e7e5ba3261dea36d5139239ddc3d014981f9
Issue: https://github.com/dart-lang/sdk/issues/46617
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/239222
Reviewed-by: Stephen Adams <sra@google.com >
Commit-Queue: Nicholas Shahan <nshahan@google.com >
2022-03-29 19:23:29 +00:00
Nicholas Shahan
5d184a74d0
[ddc] Migrate js_ast libraries to null safety
...
- characters.dart
- nodes.dart
- precedence.dart
- printer.dart
Change-Id: I038d2ea9f8a265123c34de92723078df53e5e4fe
Issue: https://github.com/dart-lang/sdk/issues/46617
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/238960
Reviewed-by: Stephen Adams <sra@google.com >
Commit-Queue: Nicholas Shahan <nshahan@google.com >
2022-03-28 23:39:20 +00:00
Brian Wilkerson
e5f118d194
Remove an unneeded ignore comment in dev_compiler
...
Change-Id: I90d4ee37e1599ad6981b379ca35c282efef923eb
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/238982
Reviewed-by: Nicholas Shahan <nshahan@google.com >
Commit-Queue: Nicholas Shahan <nshahan@google.com >
2022-03-26 00:08:27 +00:00
Nicholas Shahan
a34c8a6776
[ddc] Break SwitchCase into Case and Default nodes
...
- Removes another diff between this version and the package:js_ast.
- This is helpful for the null safety migration as the expression
in the Case node can now be non-nullable.
Change-Id: Ia6626b2ee8a4e8b66bc6b53ea74d16d2d9f81f7a
Issue: https://github.com/dart-lang/sdk/issues/46617
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/238663
Reviewed-by: Stephen Adams <sra@google.com >
Commit-Queue: Nicholas Shahan <nshahan@google.com >
2022-03-24 22:09:09 +00:00
Stephen Adams
2e984a382d
[js_ast, dev_compiler/js_ast] Use libraries instead of parts
...
This will allow more gradual migration of js_ast.
Change-Id: I3e948ad5c79fa9880b7eb3bccd7c15cbf9786e32
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/238660
Reviewed-by: Nicholas Shahan <nshahan@google.com >
Commit-Queue: Stephen Adams <sra@google.com >
2022-03-24 18:38:14 +00:00
Stephen Adams
8fb1d7084b
[js_ast, dev_compiler/js_ast] Pre-migration cleanup 1
...
This won't promote for a nullable field `foo`, so use `?.`:
if (foo != null) foo.accept(this);
-->
foo?.accept(this);
Change-Id: I0f3c92803f8756c44a959d17dfe29b12f9db362c
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/238501
Reviewed-by: Nicholas Shahan <nshahan@google.com >
Commit-Queue: Nicholas Shahan <nshahan@google.com >
2022-03-24 18:28:30 +00:00
Nicholas Shahan
ac2c6502ed
[web] Update format of comments
...
Reduce the number of diffs between pkg/js_ast and
pkg/dev_compiler/lib/src/js_ast
Change-Id: Ic00e1614b23e11118383e954a0ee31365d65ebe6
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/238388
Reviewed-by: Stephen Adams <sra@google.com >
Commit-Queue: Stephen Adams <sra@google.com >
2022-03-24 16:51:29 +00:00
Nicholas Shahan
fdf5a4130c
[ddc] Prepare nodes.dart for null safety migration
...
Preliminary changes to better isolate the nullability.
Change-Id: I3fed4ccbcb62185c84ff53e1463426322cdc1fbd
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/238387
Reviewed-by: Stephen Adams <sra@google.com >
2022-03-24 16:51:29 +00:00
pq
d2882856ef
lints 2.0 fixes
...
In anticipation of lints v 2.0.
See: https://dart-review.googlesource.com/c/sdk/+/237746
Change-Id: If6ec7f0bae314af3aa84e4d8a7b9fc1b8219c128
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/237763
Reviewed-by: Nicholas Shahan <nshahan@google.com >
Reviewed-by: Srujan Gaddam <srujzs@google.com >
Commit-Queue: Phil Quitslund <pquitslund@google.com >
2022-03-18 01:42:47 +00:00
Devon Carew
7f026d6e46
[dev_compiler] remove the dep on package:cli_util
...
Change-Id: I34c17dc76a0c608ac3536bfdf2c0e39bb8daa6c1
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/232424
Auto-Submit: Devon Carew <devoncarew@google.com >
Reviewed-by: Nicholas Shahan <nshahan@google.com >
Commit-Queue: Nicholas Shahan <nshahan@google.com >
2022-02-11 00:50:31 +00:00
Nate Bosch
33e174084a
Replace Uri.scheme == with Uri.isScheme
...
Use `hasScheme` in place of comparing against the empty string, and
`isScheme` to compare against all other schemes.
TEST=No behavior changes.
Change-Id: Ifc9fd13c6cf37933ebd4a754c4b500dedbcb291b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/231185
Reviewed-by: Kevin Moore <kevmoo@google.com >
Commit-Queue: Nate Bosch <nbosch@google.com >
2022-02-08 21:38:57 +00:00