Considerably simplify and fix the iter_lines() function
Before adoption: this commit came in with the history the project adopted, so no landing records it.
1. Do not use rstrip() as this would also throw away meaningful whitespaces 2. Avoid assuming what striplines() considers a line break terminator, the list of those is quite long in Unicode. 3. Add tests for the above edge cases.
authored by Jakub Wieczorek · committed by Jakub Wieczorek · parent 6bb0529 · Browse files · 2 files+21 added−25 removed
This commit
State
Before adoption: this commit came in with the history the project adopted, so no landing records it.
Diff stats
2 files+21 added−25 removed
- tests:+11 added−7 removed
- other:+10 added−18 removed