Skip to content

Commit b2b059c

Browse files
committed
chore: Update annotate-snippets to 0.12.10
1 parent 1d60f9e commit b2b059c

16 files changed

+73
-5
lines changed

Cargo.lock

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -74,9 +74,9 @@ dependencies = [
7474

7575
[[package]]
7676
name = "annotate-snippets"
77-
version = "0.12.9"
77+
version = "0.12.10"
7878
source = "registry+https://github.com/rust-lang/crates.io-index"
79-
checksum = "a44baf24dd94e781f74dfe67ffee75a09a57971ddf0f615a178b4f6d404b48ff"
79+
checksum = "15580ece6ea97cbf832d60ba19c021113469480852c6a2a6beb0db28f097bf1f"
8080
dependencies = [
8181
"anstyle",
8282
"memchr",
@@ -3838,7 +3838,7 @@ dependencies = [
38383838
name = "rustc_errors"
38393839
version = "0.0.0"
38403840
dependencies = [
3841-
"annotate-snippets 0.12.9",
3841+
"annotate-snippets 0.12.10",
38423842
"anstream",
38433843
"anstyle",
38443844
"derive_setters",

compiler/rustc_errors/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ edition = "2024"
55

66
[dependencies]
77
# tidy-alphabetical-start
8-
annotate-snippets = { version = "0.12.9", features = ["simd"] }
8+
annotate-snippets = { version = "0.12.10", features = ["simd"] }
99
anstream = "0.6.20"
1010
anstyle = "1.0.13"
1111
derive_setters = "0.1.6"

src/tools/clippy/tests/ui/manual_async_fn.stderr

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,9 @@ LL | fn fut() -> impl Future<Output = i32> {
99
help: make the function `async` and return the output of the future directly
1010
|
1111
LL - fn fut() -> impl Future<Output = i32> {
12+
LL -
13+
LL - async { 42 }
14+
LL - }
1215
LL + async fn fut() -> i32 { 42 }
1316
|
1417

@@ -21,6 +24,9 @@ LL | fn fut2() ->impl Future<Output = i32> {
2124
help: make the function `async` and return the output of the future directly
2225
|
2326
LL - fn fut2() ->impl Future<Output = i32> {
27+
LL -
28+
LL - async { 42 }
29+
LL - }
2430
LL + async fn fut2() -> i32 { 42 }
2531
|
2632

@@ -33,6 +39,9 @@ LL | fn fut3()-> impl Future<Output = i32> {
3339
help: make the function `async` and return the output of the future directly
3440
|
3541
LL - fn fut3()-> impl Future<Output = i32> {
42+
LL -
43+
LL - async { 42 }
44+
LL - }
3645
LL + async fn fut3() -> i32 { 42 }
3746
|
3847

@@ -45,6 +54,9 @@ LL | fn empty_fut() -> impl Future<Output = ()> {
4554
help: make the function `async` and return the output of the future directly
4655
|
4756
LL - fn empty_fut() -> impl Future<Output = ()> {
57+
LL -
58+
LL - async {}
59+
LL - }
4860
LL + async fn empty_fut() {}
4961
|
5062

@@ -57,6 +69,9 @@ LL | fn empty_fut2() ->impl Future<Output = ()> {
5769
help: make the function `async` and return the output of the future directly
5870
|
5971
LL - fn empty_fut2() ->impl Future<Output = ()> {
72+
LL -
73+
LL - async {}
74+
LL - }
6075
LL + async fn empty_fut2() {}
6176
|
6277

@@ -69,6 +84,9 @@ LL | fn empty_fut3()-> impl Future<Output = ()> {
6984
help: make the function `async` and return the output of the future directly
7085
|
7186
LL - fn empty_fut3()-> impl Future<Output = ()> {
87+
LL -
88+
LL - async {}
89+
LL - }
7290
LL + async fn empty_fut3() {}
7391
|
7492

@@ -81,6 +99,9 @@ LL | fn core_fut() -> impl core::future::Future<Output = i32> {
8199
help: make the function `async` and return the output of the future directly
82100
|
83101
LL - fn core_fut() -> impl core::future::Future<Output = i32> {
102+
LL -
103+
LL - async move { 42 }
104+
LL - }
84105
LL + async fn core_fut() -> i32 { 42 }
85106
|
86107

@@ -116,6 +137,9 @@ LL | fn elided(_: &i32) -> impl Future<Output = i32> + '_ {
116137
help: make the function `async` and return the output of the future directly
117138
|
118139
LL - fn elided(_: &i32) -> impl Future<Output = i32> + '_ {
140+
LL -
141+
LL - async { 42 }
142+
LL - }
119143
LL + async fn elided(_: &i32) -> i32 { 42 }
120144
|
121145

@@ -128,6 +152,9 @@ LL | fn explicit<'a, 'b>(_: &'a i32, _: &'b i32) -> impl Future<Output = i32> +
128152
help: make the function `async` and return the output of the future directly
129153
|
130154
LL - fn explicit<'a, 'b>(_: &'a i32, _: &'b i32) -> impl Future<Output = i32> + 'a + 'b {
155+
LL -
156+
LL - async { 42 }
157+
LL - }
131158
LL + async fn explicit<'a, 'b>(_: &'a i32, _: &'b i32) -> i32 { 42 }
132159
|
133160

@@ -140,6 +167,9 @@ LL | pub fn issue_10450() -> impl Future<Output = i32> {
140167
help: make the function `async` and return the output of the future directly
141168
|
142169
LL - pub fn issue_10450() -> impl Future<Output = i32> {
170+
LL -
171+
LL - async { 42 }
172+
LL - }
143173
LL + pub async fn issue_10450() -> i32 { 42 }
144174
|
145175

@@ -152,6 +182,9 @@ LL | pub(crate) fn issue_10450_2() -> impl Future<Output = i32> {
152182
help: make the function `async` and return the output of the future directly
153183
|
154184
LL - pub(crate) fn issue_10450_2() -> impl Future<Output = i32> {
185+
LL -
186+
LL - async { 42 }
187+
LL - }
155188
LL + pub(crate) async fn issue_10450_2() -> i32 { 42 }
156189
|
157190

@@ -164,6 +197,9 @@ LL | pub(self) fn issue_10450_3() -> impl Future<Output = i32> {
164197
help: make the function `async` and return the output of the future directly
165198
|
166199
LL - pub(self) fn issue_10450_3() -> impl Future<Output = i32> {
200+
LL -
201+
LL - async { 42 }
202+
LL - }
167203
LL + pub(self) async fn issue_10450_3() -> i32 { 42 }
168204
|
169205

src/tools/clippy/tests/ui/map_unwrap_or.stderr

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,9 @@ LL | | .unwrap_or(0);
1212
help: use `map_or(<a>, <f>)` instead
1313
|
1414
LL - let _ = opt.map(|x| x + 1)
15+
LL -
16+
LL - // Should lint even though this call is on a separate line.
17+
LL - .unwrap_or(0);
1518
LL + let _ = opt.map_or(0, |x| x + 1);
1619
|
1720

@@ -98,6 +101,7 @@ LL | | .unwrap_or(None);
98101
help: use `and_then(<f>)` instead
99102
|
100103
LL - .map(|x| Some(x + 1))
104+
LL - .unwrap_or(None);
101105
LL + .and_then(|x| Some(x + 1));
102106
|
103107

src/tools/clippy/tests/ui/match_same_arms.stderr

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,6 @@ help: otherwise remove the non-wildcard arms
3030
|
3131
LL - 2 => 'b',
3232
LL - 3 => 'b',
33-
LL + _ => 'b',
3433
|
3534

3635
error: these match arms have identical bodies

src/tools/clippy/tests/ui/non_canonical_partial_ord_impl.stderr

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,8 @@ LL | | }
2828
help: change this to
2929
|
3030
LL - fn partial_cmp(&self, _: &Self) -> Option<Ordering> {
31+
LL - todo!();
32+
LL - }
3133
LL + fn partial_cmp(&self, other: &Self) -> Option<Ordering> { Some(self.cmp(other)) }
3234
|
3335

src/tools/clippy/tests/ui/print_literal.stderr

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -310,6 +310,7 @@ LL | "name", 5, "x", 0.01
310310
help: try
311311
|
312312
LL - "Hello {}: {2} is {3:.*} (which {3} with {1} places)",
313+
LL - "name", 5, "x", 0.01
313314
LL + "Hello name: x is {1:.*} (which {1} with {0} places)", 5, 0.01
314315
|
315316

tests/ui/argument-suggestions/issue-112507.stderr

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,9 @@ help: remove the extra arguments
2020
|
2121
LL - 0,
2222
LL - None,
23+
LL - None,
24+
LL - 0,
25+
LL - );
2326
LL + None);
2427
|
2528

tests/ui/lint/invalid-nan-comparison-suggestion.stderr

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -131,6 +131,9 @@ LL | | };
131131
help: use `f32::is_nan()` or `f64::is_nan()` instead
132132
|
133133
LL - b != {
134+
LL -
135+
LL - &f32::NAN
136+
LL - };
134137
LL + !b.is_nan();
135138
|
136139

tests/ui/lint/unused/closure-body-issue-136741.stderr

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@ help: remove these parentheses
4343
|
4444
LL - let _ = (0..).find(|n| (
4545
LL - n % 2 == 0
46+
LL - ));
4647
LL + let _ = (0..).find(|n| n % 2 == 0);
4748
|
4849

0 commit comments

Comments
 (0)