From 62fd7e3bbd1e7a910de8c7865903d38edcb1ef9f Mon Sep 17 00:00:00 2001 From: John Benediktsson Date: Wed, 1 Aug 2018 21:03:40 -0700 Subject: [PATCH] tools.wc: use re-decode here also. --- extra/tools/wc/wc.factor | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/extra/tools/wc/wc.factor b/extra/tools/wc/wc.factor index c0535df1bd..94d8d3f1df 100644 --- a/extra/tools/wc/wc.factor +++ b/extra/tools/wc/wc.factor @@ -1,9 +1,9 @@ ! Copyright (C) 2016 John Benediktsson ! See http://factorcode.org/license.txt for BSD license -USING: accessors alien.data command-line formatting io -io.encodings io.encodings.binary io.files kernel math -math.bitwise math.vectors math.vectors.simd namespaces sequences +USING: alien.data command-line formatting io io.encodings +io.encodings.binary io.files kernel math math.bitwise +math.vectors math.vectors.simd namespaces sequences specialized-arrays ; SPECIALIZED-ARRAY: uchar-16 @@ -27,7 +27,7 @@ IN: tools.wc ] each-block-slice ; inline : wc-stdin ( -- n ) - input-stream get dup decoder? [ stream>> ] when + input-stream get binary re-decode [ count-lines ] with-input-stream* ; PRIVATE>