From df21c2fb81c37527ae87cd50458f1e9b88a0bfcf Mon Sep 17 00:00:00 2001 From: David A Roberts Date: Sat, 15 Aug 2015 17:25:44 +1000 Subject: [PATCH 1/2] Fix compile errors and warnings. --- main/Main.hs | 3 +-- src/Data/Multihash/Digest.hs | 1 + 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/main/Main.hs b/main/Main.hs index c7c67b1..ef94414 100644 --- a/main/Main.hs +++ b/main/Main.hs @@ -6,9 +6,8 @@ import Crypto.Hash (Digest) import qualified Crypto.Hash as CH import Data.Byteable (toBytes) import Data.ByteString (ByteString) -import Data.ByteString.Lazy (fromStrict, toStrict) +import Data.ByteString.Lazy (toStrict) import Options.Applicative -import System.Exit (exitFailure, exitSuccess) import System.IO.Streams (InputStream, stdin, stdout, withFileAsInput, write) diff --git a/src/Data/Multihash/Digest.hs b/src/Data/Multihash/Digest.hs index d059416..cc2389b 100644 --- a/src/Data/Multihash/Digest.hs +++ b/src/Data/Multihash/Digest.hs @@ -1,6 +1,7 @@ module Data.Multihash.Digest where +import Control.Applicative ((<$>)) import Data.Attoparsec.ByteString (Parser, parseOnly) import qualified Data.Attoparsec.ByteString as A import qualified Data.ByteString as BS From 061ef82400040ecab7a0875a783ce4a03950c7b9 Mon Sep 17 00:00:00 2001 From: David A Roberts Date: Sat, 15 Aug 2015 18:08:48 +1000 Subject: [PATCH 2/2] Fix typo. --- src/Data/Multihash/Digest.hs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Data/Multihash/Digest.hs b/src/Data/Multihash/Digest.hs index cc2389b..90dd4cf 100644 --- a/src/Data/Multihash/Digest.hs +++ b/src/Data/Multihash/Digest.hs @@ -16,7 +16,7 @@ import Data.Word (Word8) data MultihashDigest = MultihashDigest { algorithm :: !HashAlgorithm - , lenght :: !Length + , length :: !Length , digest :: !Digest } deriving (Show, Eq)