This commit is contained in:
Dmitry Zuikov 2023-01-13 06:00:19 +03:00
parent 1b8a9e8015
commit 3ba851a505
3 changed files with 22 additions and 6 deletions

View File

@ -64,6 +64,7 @@ library
exposed-modules: exposed-modules:
, HBS2.Defaults , HBS2.Defaults
, HBS2.Data.Types
, HBS2.Hash , HBS2.Hash
, HBS2.Merkle , HBS2.Merkle
, HBS2.Clock , HBS2.Clock

View File

@ -0,0 +1,20 @@
module HBS2.Data.Types
( module HBS2.Hash
, module HBS2.Data.Types
)
where
import HBS2.Hash
import Codec.Serialise()
import Data.Data
import Data.String(IsString)
import GHC.Generics
import Prettyprinter
newtype HashRef = HashRef (Hash HbSync)
deriving newtype (Eq,Ord,IsString,Pretty)
deriving stock (Data,Generic)
instance Serialise HashRef

View File

@ -23,14 +23,9 @@ import HBS2.Storage.Simple
import HBS2.Prelude import HBS2.Prelude
import HBS2.Prelude.Plated import HBS2.Prelude.Plated
import HBS2.Merkle import HBS2.Merkle
import HBS2.Hash import HBS2.Data.Types
import HBS2.Defaults import HBS2.Defaults
newtype HashRef = HashRef (Hash HbSync)
deriving newtype (Eq,Ord,IsString,Pretty)
deriving stock (Data,Generic)
instance Serialise HashRef
newtype OptInputFile = OptInputFile { unOptFile :: FilePath } newtype OptInputFile = OptInputFile { unOptFile :: FilePath }
deriving newtype (Eq,Ord,IsString) deriving newtype (Eq,Ord,IsString)