This commit is contained in:
Erik Svedäng 2019-05-27 10:42:22 +02:00
commit e575a6aed6
2 changed files with 2 additions and 2 deletions

View File

@ -108,7 +108,7 @@ If you want to replace all occurrences of the pattern, use `-1`.")
(doc words "splits a string into words.")
(defn words [s]
(split-by s &[\tab \space]))
(split-by s &[\tab \space \newline]))
(doc lines "splits a string into lines.")
(defn lines [s]

View File

@ -179,7 +179,7 @@
"collapse-whitespace works as expected")
(assert-equal test
&[@"erik" @"sved" @"hej" @"foo"]
&(words "erik sved hej\tfoo")
&(words "erik sved\nhej\tfoo")
"words works correctly")
(assert-equal test
&[@"erik" @"sved" @"hej" @"foo"]