on master help sign in
Define Show instance for Vect via toList.
commit64a6ceb23c8b07e764948062f74b98006ef4c215 authorMatus Tejiscak <ziman@functor.sk> dateThu 4 Dec 2014, 16:49 (12 years ago) parent7afa03a
1 file changed+1−5
libs/prelude/Prelude.idr+1−5
libs/prelude/Prelude.idr+1−5
@@ -217,11 +217,7 @@ instance Show a => Show (List a) where
217217 show' acc (x :: xs) = show' (acc ++ show x ++ ", ") xs
218218
219219instance Show a => Show (Vect n a) where
220− show xs = "[" ++ show' xs ++ "]" where
221− show' : Vect n a -> String
222− show' [] = ""
223− show' [x] = show x
224− show' (x :: xs) = show x ++ ", " ++ show' xs
220+ show = show . toList
225221
226222instance Show a => Show (Maybe a) where
227223 show Nothing = "Nothing"