Skip to content

Commit 7aabc66

Browse files
committed
Rollup merge of rust-lang#30376 - salty-horse:btree_links, r=alexcrichton
The BtreeSet main description mentions `BTreeMap`, `Ord`, `Cell`, `RefCell`. This patch adds links to their documentation.
2 parents d91c344 + 37b8e22 commit 7aabc66

File tree

1 file changed

+8
-3
lines changed
  • src/libcollections/btree

1 file changed

+8
-3
lines changed

src/libcollections/btree/set.rs

+8-3
Original file line numberDiff line numberDiff line change
@@ -26,12 +26,17 @@ use Bound;
2626

2727
/// A set based on a B-Tree.
2828
///
29-
/// See BTreeMap's documentation for a detailed discussion of this collection's performance
29+
/// See [`BTreeMap`]'s documentation for a detailed discussion of this collection's performance
3030
/// benefits and drawbacks.
3131
///
3232
/// It is a logic error for an item to be modified in such a way that the item's ordering relative
33-
/// to any other item, as determined by the `Ord` trait, changes while it is in the set. This is
34-
/// normally only possible through `Cell`, `RefCell`, global state, I/O, or unsafe code.
33+
/// to any other item, as determined by the [`Ord`] trait, changes while it is in the set. This is
34+
/// normally only possible through [`Cell`], [`RefCell`], global state, I/O, or unsafe code.
35+
///
36+
/// [`BTreeMap`]: ../struct.BTreeMap.html
37+
/// [`Ord`]: ../../core/cmp/trait.Ord.html
38+
/// [`Cell`]: ../../std/cell/struct.Cell.html
39+
/// [`RefCell`]: ../../std/cell/struct.RefCell.html
3540
#[derive(Clone, Hash, PartialEq, Eq, Ord, PartialOrd)]
3641
#[stable(feature = "rust1", since = "1.0.0")]
3742
pub struct BTreeSet<T> {

0 commit comments

Comments
 (0)