Skip to content

Commit 415a73e

Browse files
committed
docs: alias limit to Iterator::take, cite [u8]::utf8_chunks in Utf8Chunks
1 parent 7c96085 commit 415a73e

File tree

2 files changed

+3
-0
lines changed

2 files changed

+3
-0
lines changed

library/core/src/iter/traits/iterator.rs

+1
Original file line numberDiff line numberDiff line change
@@ -1358,6 +1358,7 @@ pub trait Iterator {
13581358
/// ```
13591359
///
13601360
/// [`by_ref`]: Iterator::by_ref
1361+
#[doc(alias = "limit")]
13611362
#[inline]
13621363
#[stable(feature = "rust1", since = "1.0.0")]
13631364
fn take(self, n: usize) -> Take<Self>

library/core/src/str/lossy.rs

+2
Original file line numberDiff line numberDiff line change
@@ -147,12 +147,14 @@ impl fmt::Debug for Debug<'_> {
147147
/// An iterator used to decode a slice of mostly UTF-8 bytes to string slices
148148
/// ([`&str`]) and byte slices ([`&[u8]`][byteslice]).
149149
///
150+
/// This struct is created by the [`utf8_chunks`] method on bytes slices.
150151
/// If you want a simple conversion from UTF-8 byte slices to string slices,
151152
/// [`from_utf8`] is easier to use.
152153
///
153154
/// See the [`Utf8Chunk`] type for documentation of the items yielded by this iterator.
154155
///
155156
/// [byteslice]: slice
157+
/// [`utf8_chunks`]: slice::utf8_chunks
156158
/// [`from_utf8`]: super::from_utf8
157159
///
158160
/// # Examples

0 commit comments

Comments
 (0)