Commit 9ded0d6c authored by Simon Jakobi's avatar Simon Jakobi Committed by Ben Gamari

Delete duplicate definition of fingerprintByteString

parent 8fe99c74
......@@ -151,13 +151,10 @@ import Util
import Data.List
import Data.Ord
import GHC.PackageDb (BinaryStringRep(..), DbUnitIdModuleRep(..), DbModule(..), DbUnitId(..))
import Fingerprint
import qualified Data.ByteString as BS
import qualified Data.ByteString.Unsafe as BS
import qualified Data.ByteString.Char8 as BS.Char8
import System.IO.Unsafe
import Foreign.Ptr (castPtr)
import GHC.Fingerprint
import Encoding
import qualified Text.ParserCombinators.ReadP as Parse
......@@ -847,11 +844,6 @@ rawHashUnitId sorted_holes =
fastStringToByteString (unitIdFS (moduleUnitId b)), BS.Char8.singleton ':',
toStringRep (moduleName b), BS.Char8.singleton '\n']
fingerprintByteString :: BS.ByteString -> Fingerprint
fingerprintByteString bs = unsafePerformIO
. BS.unsafeUseAsCStringLen bs
$ \(p,l) -> fingerprintData (castPtr p) l
fingerprintUnitId :: BS.ByteString -> Fingerprint -> BS.ByteString
fingerprintUnitId prefix (Fingerprint a b)
= BS.concat
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment