Skip to content

Commit 4c46116

Browse files
authored
Update sdk constraints and deps for 3.8 (#6600)
1 parent 10ebd36 commit 4c46116

File tree

54 files changed

+160
-160
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

54 files changed

+160
-160
lines changed

examples/analysis/pubspec.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ description: dart.dev example code.
33

44
resolution: workspace
55
environment:
6-
sdk: ^3.7.0
6+
sdk: ^3.8.0-0
77

88
dependencies:
99
examples_util: {path: ../util}

examples/analysis_alt/pubspec.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,4 @@ description: dart.dev example code.
33

44
resolution: workspace
55
environment:
6-
sdk: ^3.7.0
6+
sdk: ^3.8.0-0

examples/analysis_options.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,12 +21,14 @@ linter:
2121
- prefer_single_quotes
2222
- sort_child_properties_last
2323
- sort_unnamed_constructors_first
24+
- strict_top_level_inference
2425
- test_types_in_equals
2526
- throw_in_finally
2627
- type_annotate_public_apis
2728
- unawaited_futures
2829
- unnecessary_breaks
2930
- unnecessary_library_directive
3031
- unnecessary_null_aware_operator_on_extension_on_nullable
32+
- unnecessary_underscores
3133
- use_enums
3234
- use_truncating_division

examples/async_await/bin/get_order.dart

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@ Future<String> createOrderMessage() async {
44
}
55

66
Future<String> fetchUserOrder() =>
7-
// Imagine that this function is more complex and slow.
8-
Future.delayed(const Duration(seconds: 2), () => 'Large Latte');
7+
// Imagine that this function is more complex and slow.
8+
Future.delayed(const Duration(seconds: 2), () => 'Large Latte');
99

1010
// #docregion main-sig
1111
Future<void> main() async {

examples/async_await/bin/get_order_sync_bad.dart

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@ String createOrderMessage() {
77
}
88

99
Future<String> fetchUserOrder() =>
10-
// Imagine that this function is more complex and slow.
11-
Future.delayed(const Duration(seconds: 2), () => 'Large Latte');
10+
// Imagine that this function is more complex and slow.
11+
Future.delayed(const Duration(seconds: 2), () => 'Large Latte');
1212

1313
// #docregion main-sig
1414
void main() {

examples/async_await/lib/practice_errors/main.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// ignore_for_file: always_declare_return_types, type_annotate_public_apis
1+
// ignore_for_file: always_declare_return_types, type_annotate_public_apis, strict_top_level_inference
22

33
// #docregion
44
// Implement changeUsername here

examples/async_await/lib/practice_errors/test.dart

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -79,11 +79,10 @@ void passIfNoMessages(List<String> messages, Map<String, String> readable) {
7979
if (messages.isEmpty) {
8080
_result(true);
8181
} else {
82-
final userMessages =
83-
messages
84-
.where((message) => readable.containsKey(message))
85-
.map((message) => readable[message]!)
86-
.toList();
82+
final userMessages = messages
83+
.where((message) => readable.containsKey(message))
84+
.map((message) => readable[message]!)
85+
.toList();
8786
print(messages);
8887

8988
_result(false, userMessages);

examples/async_await/lib/practice_using/main.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// ignore_for_file: always_declare_return_types, type_annotate_public_apis
1+
// ignore_for_file: always_declare_return_types, type_annotate_public_apis, strict_top_level_inference
22
import 'package:examples_util/codelabs.dart';
33

44
// #docregion

examples/async_await/lib/putting_together/main.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// ignore_for_file: always_declare_return_types, type_annotate_public_apis
1+
// ignore_for_file: always_declare_return_types, type_annotate_public_apis, strict_top_level_inference
22

33
// #docregion
44
// Part 1

examples/async_await/lib/putting_together/test.dart

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -148,11 +148,10 @@ void passIfNoMessages(List<String> messages, Map<String, String> readable) {
148148
if (messages.isEmpty) {
149149
_result(true);
150150
} else {
151-
final userMessages =
152-
messages
153-
.where((message) => readable.containsKey(message))
154-
.map((message) => readable[message]!)
155-
.toList();
151+
final userMessages = messages
152+
.where((message) => readable.containsKey(message))
153+
.map((message) => readable[message]!)
154+
.toList();
156155
print(messages);
157156

158157
_result(false, userMessages);

0 commit comments

Comments
 (0)