Commit 740b8a7
authored
Rollup merge of rust-lang#80805 - camelid:iter-by_ref-example, r=steveklabnik
Improve `Iterator::by_ref` example
I split the example into two: one that fails to compile, and one that
works. I also made them identical except for the addition of `by_ref`
so we don't confuse readers with random differences.
cc `@steveklabnik,` who is the one that added the previous version of this example1 file changed
+8
-23
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1646 | 1646 | | |
1647 | 1647 | | |
1648 | 1648 | | |
1649 | | - | |
1650 | | - | |
1651 | | - | |
1652 | | - | |
1653 | | - | |
1654 | | - | |
1655 | | - | |
1656 | | - | |
1657 | | - | |
1658 | | - | |
1659 | | - | |
| 1649 | + | |
1660 | 1650 | | |
1661 | | - | |
1662 | | - | |
1663 | | - | |
1664 | | - | |
1665 | | - | |
1666 | | - | |
1667 | | - | |
| 1651 | + | |
| 1652 | + | |
| 1653 | + | |
1668 | 1654 | | |
1669 | | - | |
1670 | | - | |
1671 | | - | |
1672 | | - | |
1673 | | - | |
| 1655 | + | |
| 1656 | + | |
| 1657 | + | |
| 1658 | + | |
1674 | 1659 | | |
1675 | 1660 | | |
1676 | 1661 | | |
| |||
0 commit comments