Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rollup of 7 pull requests #86399

Merged
merged 26 commits into from
Jun 17, 2021
Merged
Changes from 1 commit
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
3803c09
Rename IoSlice(Mut)::advance to advance_slice
Thomasdezeeuw May 29, 2021
49e25b5
Add IoSlice(Mut)::advance
Thomasdezeeuw May 29, 2021
fd14c52
Rename IoSlice(Mut)::advance_slice to advance_slices
Thomasdezeeuw Jun 5, 2021
2727c3b
Document Arc::from
fee1-dead May 25, 2021
4fe4ff9
Use better error message for hard errors in CTFE
syvb Jun 15, 2021
c8a8a23
Do not emit invalid suggestions on multiple mutable borrow errors
JohnTitor Jun 16, 2021
d828ead
Remove invalid suggestions for assoc consts on placeholder type error
JohnTitor Jun 16, 2021
fb06d9e
Move some typeck-related tests to the typeck dir
JohnTitor Jun 16, 2021
044b362
Move some hard error logic to InterpError
syvb Jun 16, 2021
cb2f8d9
Make `sum()` and `product()` hyperlinks refer to `Iterator` methods.
kpreid Jun 17, 2021
ce64729
Remove methods under Implementors on trait pages
jsha Jun 3, 2021
bff4f07
Use render_impl_summary when rendering traits.
jsha Jun 8, 2021
910c7fa
Add doc(hidden) to all __iterator_get_unchecked
jsha Jun 12, 2021
593d6d1
Make portability part of the summary.
jsha Jun 8, 2021
5de1391
Factor out render_rightside
jsha Jun 12, 2021
c4fa6d5
Move anchor earlier in the DOM for easier layout
jsha Jun 17, 2021
2ac5c17
Fix target highlighting in rustdoc.
jsha Jun 17, 2021
bf81e13
Restore details for Impls on Foreign Types
jsha Jun 16, 2021
5e7a8c6
Fix typos in code examples.
m-ou-se Jun 17, 2021
36b9a6e
Rollup merge of #85663 - fee1-dead:document-arc-from, r=m-ou-se
JohnTitor Jun 17, 2021
31ee680
Rollup merge of #85802 - Thomasdezeeuw:ioslice-advance, r=m-ou-se
JohnTitor Jun 17, 2021
9521da7
Rollup merge of #85970 - jsha:remove-methods-implementors, r=Guillaum…
JohnTitor Jun 17, 2021
c062f3d
Rollup merge of #86340 - Smittyvb:ctfe-hard-error-message, r=RalfJung
JohnTitor Jun 17, 2021
afe70ee
Rollup merge of #86343 - JohnTitor:issue-85581, r=estebank
JohnTitor Jun 17, 2021
aff7994
Rollup merge of #86355 - JohnTitor:issue-82158, r=estebank
JohnTitor Jun 17, 2021
65d412b
Rollup merge of #86389 - kpreid:sum, r=scottmcm
JohnTitor Jun 17, 2021
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Make sum() and product() hyperlinks refer to Iterator methods.
The previous linking seemed confusing: within "the sum() method on
iterators", "sum()" was linked to `Sum::sum`, not `Iterator::sum`, even
though the sentence is talking about the latter.

I have rewritten the sentence to be, I believe, clearer, as well as
changing the link destinations; applying the same change to the
`Product` documentation as well as `Sum`.
kpreid committed Jun 17, 2021
commit cb2f8d9b027f01fb29487e8852d2ddb1c71ea57b
18 changes: 8 additions & 10 deletions library/core/src/iter/traits/accum.rs
Original file line number Diff line number Diff line change
@@ -3,12 +3,11 @@ use crate::num::Wrapping;

/// Trait to represent types that can be created by summing up an iterator.
///
/// This trait is used to implement the [`sum()`] method on iterators. Types which
/// implement the trait can be generated by the [`sum()`] method. Like
/// [`FromIterator`] this trait should rarely be called directly and instead
/// interacted with through [`Iterator::sum()`].
/// This trait is used to implement [`Iterator::sum()`]. Types which implement
/// this trait can be generated by using the [`sum()`] method on an iterator.
/// Like [`FromIterator`], this trait should rarely be called directly.
///
/// [`sum()`]: Sum::sum
/// [`sum()`]: Iterator::sum
/// [`FromIterator`]: iter::FromIterator
#[stable(feature = "iter_arith_traits", since = "1.12.0")]
pub trait Sum<A = Self>: Sized {
@@ -21,12 +20,11 @@ pub trait Sum<A = Self>: Sized {
/// Trait to represent types that can be created by multiplying elements of an
/// iterator.
///
/// This trait is used to implement the [`product()`] method on iterators. Types
/// which implement the trait can be generated by the [`product()`] method. Like
/// [`FromIterator`] this trait should rarely be called directly and instead
/// interacted with through [`Iterator::product()`].
/// This trait is used to implement [`Iterator::product()`]. Types which implement
/// this trait can be generated by using the [`product()`] method on an iterator.
/// Like [`FromIterator`], this trait should rarely be called directly.
///
/// [`product()`]: Product::product
/// [`product()`]: Iterator::product
/// [`FromIterator`]: iter::FromIterator
#[stable(feature = "iter_arith_traits", since = "1.12.0")]
pub trait Product<A = Self>: Sized {