@@ -252,14 +252,21 @@ tl_toUpper_upper t = p (TL.toUpper t) >= p t
252252justifyLeft k c s = s ++ L.replicate (k - length s) c
253253justifyRight m n s = L.replicate (m - length s) n ++ s
254254
255−s_justifyLeft k c = justifyLeft k c `eqP` (unpackS . S.justifyLeftI k c)
256−s_justifyLeft_s k c = justifyLeft k c `eqP` (unpackS . S.unstream . S.justifyLeftI k c)
257−sf_justifyLeft p k c =
258− (justifyLeft k c . L.filter p) `eqP` (unpackS . S.justifyLeftI k c . S.filter p)
259−t_justifyLeft k c = justifyLeft k c `eqP` (unpackS . T.justifyLeft k c)
260−tl_justifyLeft k c = justifyLeft k c `eqP` (unpackS . TL.justifyLeft (fromIntegral k) c)
261−t_justifyRight k c = justifyRight k c `eqP` (unpackS . T.justifyRight k c)
262−tl_justifyRight k c = justifyRight k c `eqP` (unpackS . TL.justifyRight (fromIntegral k) c)
255+s_justifyLeft k c = justifyLeft j c `eqP` (unpackS . S.justifyLeftI j c)
256+ where j = fromIntegral (k :: Word8)
257+s_justifyLeft_s k c = justifyLeft j c `eqP` (unpackS . S.unstream . S.justifyLeftI j c)
258+ where j = fromIntegral (k :: Word8)
259+sf_justifyLeft p k c = (justifyLeft j c . L.filter p) `eqP`
260+ (unpackS . S.justifyLeftI j c . S.filter p)
261+ where j = fromIntegral (k :: Word8)
262+t_justifyLeft k c = justifyLeft j c `eqP` (unpackS . T.justifyLeft j c)
263+ where j = fromIntegral (k :: Word8)
264+tl_justifyLeft k c = justifyLeft j c `eqP` (unpackS . TL.justifyLeft (fromIntegral j) c)
265+ where j = fromIntegral (k :: Word8)
266+t_justifyRight k c = justifyRight j c `eqP` (unpackS . T.justifyRight j c)
267+ where j = fromIntegral (k :: Word8)
268+tl_justifyRight k c = justifyRight j c `eqP` (unpackS . TL.justifyRight (fromIntegral j) c)
269+ where j = fromIntegral (k :: Word8)
263270
264271sf_foldl p f z = (L.foldl f z . L.filter p) `eqP` (S.foldl f z . S.filter p)
265272 where _types = f :: Char -> Char -> Char
@@ -330,19 +337,27 @@ tl_mapAccumR f z = unsquare (L.mapAccumR f z `eqP` (second unpackS . TL.mapAcc
330337
331338replicate n l = concat (L.replicate n l)
332339
333−t_replicate n = replicate n `eq` (unpackS . T.replicate n . packS)
334−tl_replicate n = replicate n `eq` (unpackS . TL.replicate (fromIntegral n) . packS)
340+t_replicate n = replicate m `eq` (unpackS . T.replicate m . packS)
341+ where m = fromIntegral (n :: Word8)
342+tl_replicate n = replicate m `eq` (unpackS . TL.replicate (fromIntegral m) . packS)
343+ where m = fromIntegral (n :: Word8)
335344
336345unf :: Int -> Char -> Maybe (Char, Char)
337346unf n c | fromEnum c * 100 > n = Nothing
338347 | otherwise = Just (c, succ c)
339348
340−t_unfoldr n = L.unfoldr (unf n) `eq` (unpackS . T.unfoldr (unf n))
341−tl_unfoldr n = L.unfoldr (unf n) `eq` (unpackS . TL.unfoldr (unf n))
342−t_unfoldrN n m = (L.take n . L.unfoldr (unf m)) `eq`
343− (unpackS . T.unfoldrN n (unf m))
344−tl_unfoldrN n m = (L.take n . L.unfoldr (unf m)) `eq`
345− (unpackS . TL.unfoldrN (fromIntegral n) (unf m))
349+t_unfoldr n = L.unfoldr (unf m) `eq` (unpackS . T.unfoldr (unf m))
350+ where m = fromIntegral (n :: Word16)
351+tl_unfoldr n = L.unfoldr (unf m) `eq` (unpackS . TL.unfoldr (unf m))
352+ where m = fromIntegral (n :: Word16)
353+t_unfoldrN n m = (L.take i . L.unfoldr (unf j)) `eq`
354+ (unpackS . T.unfoldrN i (unf j))
355+ where i = fromIntegral (n :: Word16)
356+ j = fromIntegral (m :: Word16)
357+tl_unfoldrN n m = (L.take i . L.unfoldr (unf j)) `eq`
358+ (unpackS . TL.unfoldrN (fromIntegral i) (unf j))
359+ where i = fromIntegral (n :: Word16)
360+ j = fromIntegral (m :: Word16)
346361
347362unpack2 :: (Stringy s) => (s,s) -> (String,String)
348363unpack2 = unpackS *** unpackS