You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Feb 25, 2025. It is now read-only.
Revamp the engine style guide, remove always_specify_types. (#52859)
Based on the (internal) discussion around converging on using the official Dart style guide, with the exception of the code that gets published under `dart:ui`, as that is user-facing, and we'd like to evolve the code style in conjunction with the framework.
I also took the opportunity to specify more about our style guide use in general, mostly to make it easier to understand our conventions, and also call out known problem areas (notably, our over-use of `shared_ptr` and `auto` in some cases). I am happy to split those up, but it was easier to make the markdown changes at once.
I also took @cbracken and folks advice and clarified directly that explicit types in Dart are _not_ bad (with examples).
Copy file name to clipboardExpand all lines: analysis_options.yaml
+3-2Lines changed: 3 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -2,7 +2,8 @@
2
2
#
3
3
# This file is a copy of analysis_options.yaml from flutter repo
4
4
# as of 2023-12-18, but with some modifications marked with
5
-
# "DIFFERENT FROM FLUTTER/FLUTTER" below.
5
+
# "DIFFERENT FROM FLUTTER/FLUTTER" below:
6
+
# - Rem
6
7
7
8
analyzer:
8
9
language:
@@ -29,7 +30,7 @@ linter:
29
30
- always_declare_return_types
30
31
- always_put_control_body_on_new_line
31
32
# - always_put_required_named_parameters_first # we prefer having parameters in the same order as fields https://github.com/flutter/flutter/issues/10219
32
-
- always_specify_types
33
+
#- always_specify_types # DIFFERENT FROM FLUTTER/FLUTTER; see https://github.com/flutter/engine/blob/main/CONTRIBUTING.md#dart
33
34
# - always_use_package_imports # we do this commonly
34
35
- annotate_overrides
35
36
# - avoid_annotating_with_dynamic # conflicts with always_specify_types
0 commit comments