]> gitweb.factorcode.org Git - factor.git/blobdiff - extra/text-analysis/text-analysis.factor
factor: qualifying blank?, random fixes, renamed test file
[factor.git] / extra / text-analysis / text-analysis.factor
index 846ed9f707fc780993b6bf40034d9d723f233d62..88f537953a995905183b84bfcb0a44616fc84bd3 100644 (file)
@@ -11,7 +11,7 @@ IN: text-analysis
 <PRIVATE
 
 : trimmed ( seq -- seq )
-    [ [ blank? ] trim ] map harvest ;
+    [ [ unicode:blank? ] trim ] map harvest ;
 
 : split-paragraphs ( str -- seq )
     R/ \r?\n\r?\n/ re-split trimmed ;
@@ -111,7 +111,7 @@ TUPLE: text-analysis #paragraphs #sentences #chars #words
     {
         [ split-paragraphs length ]
         [ split-sentences length ]
-        [ [ blank? not ] count ]
+        [ [ unicode:blank? not ] count ]
         [ split-words ]
     } cleave {
         [ length ]