Commits

FlorianHartwig committed 97c8f04

Fix forgotten exports (FromBencode and ToBencode typeclasses), use explicit
export list in types.hs

Comments (0)

Files changed (2)

src/Data/AttoBencode.hs

 module Data.AttoBencode 
-    ( BValue(..) 
+    ( BValue(..)
     , Dict
     , decode
     , encode
+    , FromBencode(..)
+    , ToBencode(..)
     ) where
 
 import Data.AttoBencode.Types

src/Data/AttoBencode/Types.hs

 {-# LANGUAGE FlexibleInstances #-}
 
-module Data.AttoBencode.Types where
+module Data.AttoBencode.Types
+    ( BValue(..)
+    , Dict
+    , FromBencode(..)
+    , ToBencode(..)
+    ) where
 
 import qualified Data.Map as M
 import Data.ByteString (ByteString)
     fromBencode _         = Nothing
 
 instance (FromBencode a) => FromBencode [a] where
-    fromBencode (BList l) = traverse fromBencode l
+    fromBencode (BList l) = sequence $ map fromBencode l
     fromBencode _         = Nothing