48615a68fb
This commit is an implementation of [RFC 1212][rfc] which tweaks the behavior of the `str::lines` and `BufRead::lines` iterators. Both iterators now account for `\r\n` sequences in addition to `\n`, allowing for less surprising behavior across platforms (especially in the `BufRead` case). Splitting *only* on the `\n` character can still be achieved with `split('\n')` in both cases. The `str::lines_any` function is also now deprecated as `str::lines` is a drop-in replacement for it. [rfc]: https://github.com/rust-lang/rfcs/blob/master/text/1212-line-endings.md Closes #28032 |
||
---|---|---|
.. | ||
btree | ||
bench.rs | ||
binary_heap.rs | ||
enum_set.rs | ||
fmt.rs | ||
lib.rs | ||
linked_list.rs | ||
slice.rs | ||
str.rs | ||
string.rs | ||
vec_deque.rs | ||
vec.rs |