Skip to content

Commit

Permalink
Rollup merge of rust-lang#55711 - kngwyu:btreemap-rangemut-doc, r=Mar…
Browse files Browse the repository at this point in the history
  • Loading branch information
pietroalbini committed Nov 12, 2018
2 parents 1a61f26 + 1224e01 commit d1af662
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/liballoc/collections/btree/map.rs
Original file line number Diff line number Diff line change
Expand Up @@ -853,9 +853,10 @@ impl<K: Ord, V> BTreeMap<K, V> {
/// ```
/// use std::collections::BTreeMap;
///
/// let mut map: BTreeMap<&str, i32> = ["Alice", "Bob", "Carol", "Cheryl"].iter()
/// .map(|&s| (s, 0))
/// .collect();
/// let mut map: BTreeMap<&str, i32> = ["Alice", "Bob", "Carol", "Cheryl"]
/// .iter()
/// .map(|&s| (s, 0))
/// .collect();
/// for (_, balance) in map.range_mut("B".."Cheryl") {
/// *balance += 100;
/// }
Expand Down

0 comments on commit d1af662

Please sign in to comment.