diff options
| author | Jacob Pratt <jacob@jhpratt.dev> | 2025-03-30 17:59:29 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-03-30 17:59:29 -0400 |
| commit | a99b5339f4639615cc0f0cd60a6c1e75c17b1c03 (patch) | |
| tree | 278b4e2217a51ef4401105d2ef5f29ce27ce4630 /library/core | |
| parent | f07a0d117faf37a4bfd6bc6ba91602b456b6b344 (diff) | |
| parent | 41bee761bb81888c09c0567377abdcacf564f6b9 (diff) | |
| download | rust-a99b5339f4639615cc0f0cd60a6c1e75c17b1c03.tar.gz rust-a99b5339f4639615cc0f0cd60a6c1e75c17b1c03.zip | |
Rollup merge of #139141 - mejrs:on_unimpl, r=Noratrieb
Switch some rustc_on_unimplemented uses to diagnostic::on_unimplemented The use on the SliceIndex impl appears unreachable, there is no mention of "vector indices" in any test output and I could not get it to show up in error messages.
Diffstat (limited to 'library/core')
| -rw-r--r-- | library/core/src/iter/traits/accum.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/library/core/src/iter/traits/accum.rs b/library/core/src/iter/traits/accum.rs index 5b7d95c2f65..12e2b8b393a 100644 --- a/library/core/src/iter/traits/accum.rs +++ b/library/core/src/iter/traits/accum.rs @@ -10,7 +10,7 @@ use crate::num::Wrapping; /// [`sum()`]: Iterator::sum /// [`FromIterator`]: iter::FromIterator #[stable(feature = "iter_arith_traits", since = "1.12.0")] -#[rustc_on_unimplemented( +#[diagnostic::on_unimplemented( message = "a value of type `{Self}` cannot be made by summing an iterator over elements of type `{A}`", label = "value of type `{Self}` cannot be made by summing a `std::iter::Iterator<Item={A}>`" )] @@ -31,7 +31,7 @@ pub trait Sum<A = Self>: Sized { /// [`product()`]: Iterator::product /// [`FromIterator`]: iter::FromIterator #[stable(feature = "iter_arith_traits", since = "1.12.0")] -#[rustc_on_unimplemented( +#[diagnostic::on_unimplemented( message = "a value of type `{Self}` cannot be made by multiplying all elements of type `{A}` from an iterator", label = "value of type `{Self}` cannot be made by multiplying all elements from a `std::iter::Iterator<Item={A}>`" )] |
