88 Commits

Author SHA1 Message Date
Kate Lovett
a04fb324be
Bump Dart to 3.8 and reformat (#171703)
Bumps the Dart version to 3.8 across the repo (excluding
engine/src/flutter/third_party) and applies formatting updates from Dart
3.8.

## Pre-launch Checklist

- [x] I read the [Contributor Guide] and followed the process outlined
there for submitting PRs.
- [x] I read the [Tree Hygiene] wiki page, which explains my
responsibilities.
- [x] I read and followed the [Flutter Style Guide], including [Features
we expect every widget to implement].
- [x] I signed the [CLA].
- [ ] I listed at least one issue that this PR fixes in the description
above.
- [ ] I updated/added relevant documentation (doc comments with `///`).
- [x] I added new tests to check the change I am making, or this PR is
[test-exempt].
- [x] I followed the [breaking change policy] and added [Data Driven
Fixes] where supported.
- [x] All existing and new tests are passing.

If you need help, consider asking for advice on the #hackers-new channel
on [Discord].

<!-- Links -->
[Contributor Guide]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md#overview
[Tree Hygiene]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md
[test-exempt]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md#tests
[Flutter Style Guide]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Style-guide-for-Flutter-repo.md
[Features we expect every widget to implement]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Style-guide-for-Flutter-repo.md#features-we-expect-every-widget-to-implement
[CLA]: https://cla.developers.google.com/
[flutter/tests]: https://github.com/flutter/tests
[breaking change policy]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md#handling-breaking-changes
[Discord]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Chat.md
[Data Driven Fixes]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Data-driven-Fixes.md
2025-07-07 17:58:32 +00:00
Michael Goderbauer
8e0993eda8
Auto-format Dart code in engine (#160576)
This auto-formats all *.dart files in the `engine` subdirectory and
enforces that these files stay formatted with a presubmit check.
2024-12-19 17:13:07 +00:00
Michael Goderbauer
75f9549553 Bump Dart SDK to 3.7 (flutter/engine#56989) 2024-12-06 01:41:03 +00:00
gaaclarke
9f66178386 Reland: Update Color to do all calculations with floating point components (flutter/engine#55231)
Reason for revert: Broke customer tests
Reland depends on https://github.com/flutter/flutter/issues/155113

This transforms the rest of Color to use the floating point parameters.  This will likely break existing tests very subtly.  For example, colors will be slightly different in golden tests if `lerp` was ever used.

issue: https://github.com/flutter/flutter/issues/127855

[C++, Objective-C, Java style guides]: https://github.com/flutter/engine/blob/main/CONTRIBUTING.md#style
2024-09-23 17:43:52 +00:00
gaaclarke
f9093e1b13 Revert "Update Color to do all calculations with floating point components" (flutter/engine#55153)
Reverts flutter/engine#54981

This is causing failures in customer tests that need to be updated:
https://github.com/flutter/flutter/pull/155107/checks?check_run_id=30069840819
2024-09-12 13:01:37 -07:00
Matan Lurey
37f629a23f Migrate more tests from litetest to package:test (flutter/engine#55119)
Partial work towards https://github.com/flutter/flutter/issues/133569.

Commentary on removal of `assert`-conditionals here: https://github.com/flutter/flutter/issues/155054.
2024-09-12 19:01:05 +00:00
gaaclarke
c7d96a38bc Update Color to do all calculations with floating point components (flutter/engine#54981)
This transforms the rest of Color to use the floating point parameters.  This will likely break existing tests very subtly.  For example, colors will be slightly different in golden tests if `lerp` was ever used.

issue: https://github.com/flutter/flutter/issues/127855

[C++, Objective-C, Java style guides]: https://github.com/flutter/engine/blob/main/CONTRIBUTING.md#style
2024-09-12 16:30:06 +00:00
Matan Lurey
c5f302cd01 Move flutter_frontend_server and tweak run_tests.py to allow env variables. (flutter/engine#55089)
Work towards https://github.com/flutter/flutter/issues/133569.

After another PR, `run_tests.py` `extra_args` can be deleted entirely.
2024-09-10 23:35:05 +00:00
Matan Lurey
66d00dddf8 Migrate the remaining real pub packages to pub workspaces. (flutter/engine#54232)
Closes https://github.com/flutter/flutter/issues/147883.
2024-07-31 09:51:27 -07:00
Jason Simmons
f745408809 Move the Dart SDK to //flutter/third_party/dart (flutter/engine#51917) 2024-04-09 12:48:09 +00:00
Jason Simmons
209b89244a Use the AOT snapshot built by the Dart SDK for the frontend server (flutter/engine#51943)
Dart will be removing the frontend server JIT snapshot.
(see https://dart.googlesource.com/sdk/+/e6c9eaaf6b63e5d3d0eefd7e95df9d10d9a25569)
2024-04-08 18:38:03 +00:00
auto-submit[bot]
ee494ad4dd Reverts "Manual Dart roll to 0ac840ba1 and update frontend server snapshot filename (#51921)" (flutter/engine#51927)
Reverts: flutter/engine#51921
Initiated by: zanderso
Reason for reverting: This Dart roll is blocking the roll of the engine to the framework. Unblocking the rolls depends on addressing https://github.com/flutter/flutter/issues/146164.
Original PR Author: jason-simmons

Reviewed By: {zanderso, jonahwilliams}

This change reverts the following previous change:
The Dart SDK is now only building an AOT snapshot for the frontend server (see https://dart-review.googlesource.com/c/sdk/+/359100)
2024-04-05 02:27:25 +00:00
Jason Simmons
564fc1e2d4 Manual Dart roll to 0ac840ba1 and update frontend server snapshot filename (flutter/engine#51921)
The Dart SDK is now only building an AOT snapshot for the frontend server (see https://dart-review.googlesource.com/c/sdk/+/359100)
2024-04-04 22:14:02 +00:00
William Hesse
1e43ea059b Add support for dart_src GN variable to flutter_frontend_server build (flutter/engine#50685)
Support for the dart_src GN variable was missing the import of the variable definition in the flutter_frontend_server BUILD.gn file.

Follow up to https://github.com/flutter/engine/pull/50624/

Part of issue https://github.com/flutter/flutter/issues/143335
2024-02-15 16:02:56 +00:00
Chinmay Garde
6c17d7bf9d Use a GN variable (dart_src) to reference the location of the Dart checkout. (flutter/engine#50624)
Towards https://github.com/flutter/flutter/issues/143335
2024-02-14 21:12:23 -08:00
Zachary Anderson
70ba5c45fb Reland: Remove the frontend server wrapper (flutter/engine#47010)
Relands https://github.com/flutter/engine/pull/46440 with https://github.com/flutter/engine/pull/46842
2023-10-18 20:32:37 +00:00
Zachary Anderson
35f53fe500 Revert "Remove the frontend server wrapper" (flutter/engine#46863)
Reverts flutter/engine#46440

For b/305121780
2023-10-12 20:42:35 -07:00
Zachary Anderson
23b6f6116f Remove the frontend server wrapper (flutter/engine#46440)
Instead, this PR copies the frontend server from the Dart SDK (whether prebuilt or not) into the location expected by internal engine tests and artifact construction. This PR also consolidates the three GN templates that invoked the frontend server down to one.

Framework presubs: https://github.com/flutter/flutter/pull/135836

Related: https://github.com/flutter/flutter/issues/60007
2023-10-12 15:40:50 +00:00
Matan Lurey
2b54d1a9e6 Remove support for Paint.enableDithering=false in dart:ui. (flutter/engine#46745)
Work towards https://github.com/flutter/flutter/issues/112498.

No behavioral changes to existing code, except `Paint.enableDithering = false` will no longer be an option.
2023-10-11 01:24:16 +00:00
Michael Goderbauer
efc22ee283 Enable private field promotion (flutter/engine#45722)
New feature in upcoming Dart 3.2. See https://github.com/dart-lang/language/issues/2020. Feature is enabled by bumping the min SDK version to 3.2.

Part of https://github.com/flutter/flutter/issues/134476.
2023-09-14 21:02:03 +00:00
William Hesse
5161f30cf7 Add dart2wasm dependency to flutter_frontend_server (flutter/engine#45570)
The change
https://dart-review.googlesource.com/c/sdk/+/323000 added a dependency on dart2wasm to the frontend_server package.

Flutter engine has all dependencies in its source checkout, and paths to their locations hardcoded in the dependency_ovedrrides of flutter_frontend_server's pubspec.yaml.

Add the dart2wasm package location to pubspec.yaml. Add the transitive dependency wasm_builder package lcoation to pubspec.yaml.
2023-09-08 10:47:22 +00:00
Matan Lurey
a330c4ff97 Update (flipping the default from false -> true) and deprecate Paint.enableDithering. (flutter/engine#44705)
Update: Blocked on https://github.com/flutter/engine/pull/44912 landing,
and merging into google3.

---

Partial work towards https://github.com/flutter/flutter/issues/112498.

_**tl;dr**: In Impeller's backend we intend to _always_ dither
gradients, and never allow any changes long-term (i.e., write your own
shader if you want different behavior) with the assumption that dithered
gradients look better most of the time, and don't typically hurt
elsewhere._

Note that, at the time of this writing, I couldn't find a single case of
this being set explicitly to `true` inside Google, and there are between
[100 and 200 publicly accessible on
GitHub](https://github.com/search?q=%22Paint.enableDithering%22+language%3ADart&type=code&l=Dart),
of which virtually all are setting it explicitly to `true`.

There are some (valid) concerns this would cause a lot of golden-file
image diffs, so I'm going to seek explicit approval from the Google
testing team as well as someone from the framework team before landing
this commit.
2023-09-01 10:19:59 -07:00
Jacob MacDonald
660bdd6b03 add dart_internal override where necessary (flutter/engine#42920)
A dependency to dart_internal was added in https://dart-review.googlesource.com/c/sdk/+/309460/6 and all transitive deps need to have overrides.
2023-06-16 17:20:18 +00:00
Michael Goderbauer
a508065bbc Reland "Post 3.0 lint sync (#40394)" (flutter/engine#40688)
Reland "Post 3.0 lint sync (#40394)"
2023-03-28 03:25:02 +00:00
Brandon DeRosier
9e9590a68f Revert "Post 3.0 lint sync (#40394)" (flutter/engine#40687)
This reverts commit 8ba209121d2671b0d202d9731fe67ec5eb1529b4.
2023-03-27 15:45:59 -07:00
Michael Goderbauer
8ba209121d Post 3.0 lint sync (flutter/engine#40394)
Post 3.0 lint sync
2023-03-27 17:15:08 +00:00
Michael Goderbauer
dcc4b1b535 Reland: Bump lower Dart SDK constraints to 3.0 (flutter/engine#40318)
* WIP

Bump to 3.0.0-0

* fix lints

* drop web_ui

* opt pointer_converter.dart out of dart 3

* Revert "drop web_ui"

This reverts commit b97a015d5cd0d7e0380a4231be4c31aad36671f1.
2023-03-16 08:07:39 -07:00
Zachary Anderson
32b3e66d7c Revert "Bump lower Dart SDK constraints to 3.0 (#40178)" (flutter/engine#40317)
Revert "Bump lower Dart SDK constraints to 3.0"
2023-03-15 18:53:00 +00:00
Michael Goderbauer
828f3deb86 Bump lower Dart SDK constraints to 3.0 (flutter/engine#40178)
Bump lower Dart SDK constraints to 3.0
2023-03-15 17:57:04 +00:00
Martin Kustermann
a607bb8bce Add mmap dependency to flutter_frontend_server (flutter/engine#39090)
In a follow-up change in Dart SDK, package:compiler (a dependency of
flutter_frontend_server) will start using package:mmap
2023-01-24 09:35:05 +01:00
Martin Kustermann
ce0fa20e44 Add package:ffi as path dependency to flutter_frontend_server (flutter/engine#37802)
The CL in [0] added package:ffi as dependency to package:compiler. Since
flutter_frontend_server needs all dependencies as path dependencies, we
need to add package:ffi there via path.

[0] https://dart-review.googlesource.com/c/sdk/+/269640
2022-11-21 14:49:11 +01:00
Siva
9d3a153bfa Update language version in flutter_frontend_server/test/fixtures (flutter/engine#37643)
package.
2022-11-15 22:53:20 +00:00
Siva
d4a1f7a64b Make Flutter frontend server Null safe. (flutter/engine#36482) 2022-09-28 13:24:07 -07:00
Zachary Anderson
5110627208 Revert "Make flutter frontend server null safe" (flutter/engine#36417) 2022-09-26 17:07:21 +00:00
Siva
bc00fefdc6 Make flutter frontend server null safe (flutter/engine#36394) 2022-09-24 13:45:28 +00:00
Michael Goderbauer
cc50c5249c Sync analysis_options.yaml with flutter/flutter (flutter/engine#34986) 2022-07-29 16:41:04 -07:00
William Hesse
737d5b5d70 Support new package dependency in flutter_frontend_server (flutter/engine#34996) 2022-07-29 13:43:04 +00:00
Márk Tolmács
c85e3529b1 Fix tests on the Windows platform (flutter/engine#34350)
Addresses https://github.com/flutter/flutter/issues/36301
2022-07-11 11:01:05 -07:00
Devon Carew
5f127682d3 update for the latest Dart SDK roll (flutter/engine#34025)
* update for the latest Dart SDK roll

* Update DEPS

update the dart revision to 204b67e5a029de64899154068cf1099b4f7db1f1

* Update license hash

Co-authored-by: Alexander Aprelev <aam@google.com>
2022-06-13 23:02:30 -07:00
William Hesse
dedb924576 Remove dependencies on package charcode (flutter/engine#33925)
The charcode package has been removed from the Dart SDK source
checkout, and the Flutter engine packages that list it in
their pubspecs do not depend on it directly or indirectly.

Remove it from their pubspecs, so they do not break when
the package disappears from the engine source checkout.

Bug: https://dart-review.googlesource.com/c/sdk/+/247500
2022-06-09 08:04:35 -07:00
Devon Carew
8ee8abc1f7 reduce the number of dependencies declared by flutter_frontend_server (flutter/engine#33520)
reduce the number of dependencies declared by flutter_frontend_server
2022-05-22 18:38:40 -07:00
Alexander Markov
2774c081e1 Add dependency_override for the new implicit dependency of frontend-server: vm_service (flutter/engine#33495)
The new dependency was added in Dart SDK in dart-lang/sdk@077a790.
This change is needed to unblock the Dart SDK -> engine roll.
2022-05-19 15:33:34 -07:00
Alexander Markov
3e5a9e8aba Roll Dart SDK to 5dd26db806f52452a3da07f0ac8ab73efff9f213 (flutter/engine#33489)
Roll Dart SDK manually in order to update flutter_frontend_server/pubspec.yaml after https://dart-review.googlesource.com/c/sdk/+/238300.

The following changes are included into this roll: https://dart.googlesource.com/sdk.git/+log/bfa317943967fc28ff5c3a133fcd7de6dc566e7e..5dd26db806f52452a3da07f0ac8ab73efff9f213
2022-05-19 13:51:23 -07:00
Alexander Aprelev
18feb21f13 Roll dart sdk to 1bdb83bddf96c41cc046810c697a2c80bfaaaf19 (flutter/engine#33416)
* Roll dart sdk to 1bdb83bddf96c41cc046810c697a2c80bfaaaf19

Changes since las troll:
```
1bdb83bddf9 Version 2.18.0-122.0.dev
6ebd2633cd7 Use `any` deps for all unpublished packages
09b7f36b2fa [vm, compiler] Support ShadowCallStack on Fuchsia RISC-V.
e1773c7ebc3 Bump boolean_selector to 1d3565e2651d16566bb556955b96ea75018cbd0c
ae727399f2e [pkg/meta] prep for publishing package:meta 1.8.0
7b578ca6166 Add experimental flag `inference-update-2`.
5729605e183 [dart2wasm] Implement `FunctionType` Type.
c6d5cd043b8 [js_util] Add `dartify` and some helpers.
2b8429252e9 Issue 49031. Read files during applyPendingFileChanges(), so getFile() uses new content.
36acc59dcbb [analyser] support code completion for `errors` and `enable-experiment`
dd298c1ca36 Use a wrapper object for allResults in AnalysisDriver tests.
eb458cf46a9 [build] Fix false detection of compressed pointers as cross builds.
bbd7e5a4d9f Fix bad sdk-path error message
b36f4518bf9 Bump webkit_inspection_protocol to e4965778e2837adc62354eec3a19123402997897
```

* Update license hash
2022-05-17 00:31:52 -07:00
Alexander Aprelev
e6f8a8d590 Roll dart sdk to 7b24ff4d92e2d2136020fc5bedadfe7025861510 (flutter/engine#33309)
* Roll dart sdk to 7b24ff4d92e2d2136020fc5bedadfe7025861510

Changes since last roll:

```
7b24ff4d92e Version 2.18.0-111.0.dev
37eff8b8bcd Revert "[vm, compiler] Let SIMD values become constants."
f8645091bdc Version 2.18.0-110.0.dev
07aeba22865 Add implementations for LibraryAugmentationElementImpl and friends.
292e92be2d9 Move more completion override tests to run on both protocols.
1e04fe1fd05 Reland "Sync packages from shelf mono repo"
9f149e9f5db Bump pool to c40cc32eabecb9d60f1045d1403108d968805f9a
f5af2d9e776 Use ParameterMember when substituting function types.
e593b865b23 Prepare to publish analyzer_plugin 0.10.0
bcc7bda3d8e [analysis_server] Sort fields, enum members and base types consistently
bdacbb8decb [vm, compiler] Let SIMD values become constants.
862a2c6caf8 Roll zlib to pick up more 1.2.12 fixes
6ac1718994c Make typeParameterDeclaration implement TypeDeclaration
1cdc606ab3d [vm, compiler] Include the global object pool in AOT's --disassemble.
885d7843a73 [vm, compiler] Shorter LoadImmediate sequences for RV64.
8f3284098cd Declare LibraryAugmentationElement and AugmentationImportElement.
a9804e3259d [analysis_server] Simplify types for LSP documentChanges
8188d2824a8 Bump pub to 51435efcd574b7bc18d47a5dd620cb9759dea8f8
c0c51c2279c [infra] Upgrade checked-in SDKs to 2.17.0
```

* Update license hash
2022-05-13 08:03:37 -07:00
Alexander Aprelev
ef654d96c2 Remove unused pkg/pedantic dependency. (flutter/engine#32894)
The dependency is unused, but causes breakages during dart->engine roll since https://dart.googlesource.com/sdk/+/aa63ef8f4f506ffa9f160b960158e861be370b4a removed it from dart sdk.
2022-04-25 06:39:10 -07:00
Alexander Aprelev
2dd70761f3 Add pkg:smith as a dependency for flutter_frontend_server. (flutter/engine#30903)
* Add pkg:smith as a dependency for flutter_frontend_server.

This is needed to roll dart past b453c6bcba

* Update few more packages that depend on internal dart sdk expect package
2022-01-18 09:26:55 -08:00
Dan Field
a2a3c9643c Remove obsolete instructions from scenario_app readme, pass depfile correctly. (flutter/engine#28732) 2021-09-23 14:13:01 -07:00
Zachary Anderson
75c1fbccc7 Don't use Dart's application_snapshot() rule (flutter/engine#28361) 2021-09-16 13:37:01 -07:00
Alexander Aprelev
80efe6e5c9 Roll dart to 2.15.0-18.0.dev (flutter/engine#28107)
* Roll dart to 2.15.0-18.0.dev

Changes since last roll:
```
d39206fb4e2 (tag: 2.15.0-18.0.dev) Version 2.15.0-18.0.dev
6e28f8bb404 [vm] Avoid reserved register error on newer compilers
d2bd43f43e6 [python3] Migrate PRESUBMIT.py files
79be5898b46 [co19] LibTests/typed_data tests skipped for dart2js
af6f6cf9826 (tag: 2.15.0-17.0.dev) Version 2.15.0-17.0.dev
f0f94705a49 In ScopeResolverVisitor, don't visit identifiers to the right of `.`.
6274633ea1b Merge ScopedVisitor with ScopeResolverVisitor classes.
80ec62a3fd2 (tag: 2.15.0-16.0.dev) Version 2.15.0-16.0.dev
fc4d4144fb0 (origin/base) Added js_util import to html_dart2js
d2855e703e2 [ CLI ] Default to printing CLI usage message instead of VM usage
af2ec43d447 [vm/compiler] Fix incorrect assertion in LoadOptimizer
3365b77ac2d use code from package:devtools_shared
16ff4aec0ea Revert "[vm] Hide internal implementation List types and expose them as List"
6465ee4ad8a analyze pkg/nnbd_migration on the bots
cd6fb671034 [vm] Clean up changes around internal-only class ids.
7ac9c46977b [dart2js_info] Fix tests after migration.
1f405bf163c [VM/Runtime] Added a Dart VM initialization state to prevent racy access              to VM state from Dart API calls.
824bec596f5 [vm] Hide internal implementation List types and expose them as List
```
2021-08-16 11:29:42 -07:00