darcs-2.18.3: a distributed, interactive, smart revision control system
Safe HaskellSafe-Inferred
LanguageHaskell2010

Darcs.Patch.Witnesses.Eq

Synopsis

Documentation

data EqCheck wA wB where Source #

EqCheck is used to pass around evidence (or lack thereof) of two witness types being equal.

Constructors

IsEq :: EqCheck wA wA 
NotEq :: EqCheck wA wB 

Instances

Instances details
Show (EqCheck wA wB) Source # 
Instance details

Defined in Darcs.Patch.Witnesses.Eq

Methods

showsPrec :: Int -> EqCheck wA wB -> ShowS #

show :: EqCheck wA wB -> String #

showList :: [EqCheck wA wB] -> ShowS #

Eq (EqCheck wA wB) Source # 
Instance details

Defined in Darcs.Patch.Witnesses.Eq

Methods

(==) :: EqCheck wA wB -> EqCheck wA wB -> Bool #

(/=) :: EqCheck wA wB -> EqCheck wA wB -> Bool #

class Eq2 p where Source #

An witness aware equality class. A minimal definition defines any one of unsafeCompare, =\/= and =/\=.

Minimal complete definition

unsafeCompare | (=\/=) | (=/\=)

Methods

unsafeCompare :: p wA wB -> p wC wD -> Bool Source #

It is unsafe to define a class instance via this method, because if it returns True then the default implementations of =\/= and =/\= will coerce the equality of two witnesses.

Calling this method is safe, although =\/= or =/\= would be better choices as it is not usually meaningul to compare two patches that don't share either a starting or an ending context

(=\/=) :: p wA wB -> p wA wC -> EqCheck wB wC infix 4 Source #

Compare two things with the same starting witness. If the things compare equal, evidence of the ending witnesses being equal will be returned.

(=/\=) :: p wA wC -> p wB wC -> EqCheck wA wB infix 4 Source #

Compare two things with the same ending witness. If the things compare equal, evidence of the starting witnesses being equal will be returned.

Instances

Instances details
Eq2 Hunk Source # 
Instance details

Defined in Darcs.Patch.Prim.FileUUID.Core

Methods

unsafeCompare :: Hunk wA wB -> Hunk wC wD -> Bool Source #

(=\/=) :: Hunk wA wB -> Hunk wA wC -> EqCheck wB wC Source #

(=/\=) :: Hunk wA wC -> Hunk wB wC -> EqCheck wA wB Source #

Eq2 HunkMove Source # 
Instance details

Defined in Darcs.Patch.Prim.FileUUID.Core

Methods

unsafeCompare :: HunkMove wA wB -> HunkMove wC wD -> Bool Source #

(=\/=) :: HunkMove wA wB -> HunkMove wA wC -> EqCheck wB wC Source #

(=/\=) :: HunkMove wA wC -> HunkMove wB wC -> EqCheck wA wB Source #

Eq2 Prim Source # 
Instance details

Defined in Darcs.Patch.Prim.FileUUID.Core

Methods

unsafeCompare :: Prim wA wB -> Prim wC wD -> Bool Source #

(=\/=) :: Prim wA wB -> Prim wA wC -> EqCheck wB wC Source #

(=/\=) :: Prim wA wC -> Prim wB wC -> EqCheck wA wB Source #

Eq2 DirPatchType Source # 
Instance details

Defined in Darcs.Patch.Prim.V1.Core

Methods

unsafeCompare :: DirPatchType wA wB -> DirPatchType wC wD -> Bool Source #

(=\/=) :: DirPatchType wA wB -> DirPatchType wA wC -> EqCheck wB wC Source #

(=/\=) :: DirPatchType wA wC -> DirPatchType wB wC -> EqCheck wA wB Source #

Eq2 FilePatchType Source # 
Instance details

Defined in Darcs.Patch.Prim.V1.Core

Methods

unsafeCompare :: FilePatchType wA wB -> FilePatchType wC wD -> Bool Source #

(=\/=) :: FilePatchType wA wB -> FilePatchType wA wC -> EqCheck wB wC Source #

(=/\=) :: FilePatchType wA wC -> FilePatchType wB wC -> EqCheck wA wB Source #

Eq2 Prim Source # 
Instance details

Defined in Darcs.Patch.Prim.V1.Core

Methods

unsafeCompare :: Prim wA wB -> Prim wC wD -> Bool Source #

(=\/=) :: Prim wA wB -> Prim wA wC -> EqCheck wB wC Source #

(=/\=) :: Prim wA wC -> Prim wB wC -> EqCheck wA wB Source #

Eq2 RebaseName Source # 
Instance details

Defined in Darcs.Patch.Rebase.Name

Methods

unsafeCompare :: RebaseName wA wB -> RebaseName wC wD -> Bool Source #

(=\/=) :: RebaseName wA wB -> RebaseName wA wC -> EqCheck wB wC Source #

(=/\=) :: RebaseName wA wC -> RebaseName wB wC -> EqCheck wA wB Source #

Eq2 Prim Source # 
Instance details

Defined in Darcs.Patch.V1.Prim

Methods

unsafeCompare :: Prim wA wB -> Prim wC wD -> Bool Source #

(=\/=) :: Prim wA wB -> Prim wA wC -> EqCheck wB wC Source #

(=/\=) :: Prim wA wC -> Prim wB wC -> EqCheck wA wB Source #

Eq2 Prim Source # 
Instance details

Defined in Darcs.Patch.V2.Prim

Methods

unsafeCompare :: Prim wA wB -> Prim wC wD -> Bool Source #

(=\/=) :: Prim wA wB -> Prim wA wC -> EqCheck wB wC Source #

(=/\=) :: Prim wA wC -> Prim wB wC -> EqCheck wA wB Source #

Eq2 p => Eq2 (Invertible p) Source # 
Instance details

Defined in Darcs.Patch.Invertible

Methods

unsafeCompare :: Invertible p wA wB -> Invertible p wC wD -> Bool Source #

(=\/=) :: Invertible p wA wB -> Invertible p wA wC -> EqCheck wB wC Source #

(=/\=) :: Invertible p wA wC -> Invertible p wB wC -> EqCheck wA wB Source #

(Commute p, Eq2 p) => Eq2 (Named p) Source # 
Instance details

Defined in Darcs.Patch.Named

Methods

unsafeCompare :: Named p wA wB -> Named p wC wD -> Bool Source #

(=\/=) :: Named p wA wB -> Named p wA wC -> EqCheck wB wC Source #

(=/\=) :: Named p wA wC -> Named p wB wC -> EqCheck wA wB Source #

Eq2 p => Eq2 (Hopefully p) Source # 
Instance details

Defined in Darcs.Patch.PatchInfoAnd

Methods

unsafeCompare :: Hopefully p wA wB -> Hopefully p wC wD -> Bool Source #

(=\/=) :: Hopefully p wA wB -> Hopefully p wA wC -> EqCheck wB wC Source #

(=/\=) :: Hopefully p wA wC -> Hopefully p wB wC -> EqCheck wA wB Source #

Eq2 p => Eq2 (PatchInfoAndG p) Source # 
Instance details

Defined in Darcs.Patch.PatchInfoAnd

Methods

unsafeCompare :: PatchInfoAndG p wA wB -> PatchInfoAndG p wC wD -> Bool Source #

(=\/=) :: PatchInfoAndG p wA wB -> PatchInfoAndG p wA wC -> EqCheck wB wC Source #

(=/\=) :: PatchInfoAndG p wA wC -> PatchInfoAndG p wB wC -> EqCheck wA wB Source #

Eq2 prim => Eq2 (RepoPatchV1 prim) Source # 
Instance details

Defined in Darcs.Patch.V1.Commute

Methods

unsafeCompare :: RepoPatchV1 prim wA wB -> RepoPatchV1 prim wC wD -> Bool Source #

(=\/=) :: RepoPatchV1 prim wA wB -> RepoPatchV1 prim wA wC -> EqCheck wB wC Source #

(=/\=) :: RepoPatchV1 prim wA wC -> RepoPatchV1 prim wB wC -> EqCheck wA wB Source #

PrimPatch prim => Eq2 (RepoPatchV2 prim) Source # 
Instance details

Defined in Darcs.Patch.V2.RepoPatch

Methods

unsafeCompare :: RepoPatchV2 prim wA wB -> RepoPatchV2 prim wC wD -> Bool Source #

(=\/=) :: RepoPatchV2 prim wA wB -> RepoPatchV2 prim wA wC -> EqCheck wB wC Source #

(=/\=) :: RepoPatchV2 prim wA wC -> RepoPatchV2 prim wB wC -> EqCheck wA wB Source #

Eq2 p => Eq2 (FL p) Source # 
Instance details

Defined in Darcs.Patch.Witnesses.Ordered

Methods

unsafeCompare :: FL p wA wB -> FL p wC wD -> Bool Source #

(=\/=) :: FL p wA wB -> FL p wA wC -> EqCheck wB wC Source #

(=/\=) :: FL p wA wC -> FL p wB wC -> EqCheck wA wB Source #

Eq2 p => Eq2 (RL p) Source # 
Instance details

Defined in Darcs.Patch.Witnesses.Ordered

Methods

unsafeCompare :: RL p wA wB -> RL p wC wD -> Bool Source #

(=\/=) :: RL p wA wB -> RL p wA wC -> EqCheck wB wC Source #

(=/\=) :: RL p wA wC -> RL p wB wC -> EqCheck wA wB Source #

(Eq name, Eq2 p) => Eq2 (PrimWithName name p) Source # 
Instance details

Defined in Darcs.Patch.Prim.WithName

Methods

unsafeCompare :: PrimWithName name p wA wB -> PrimWithName name p wC wD -> Bool Source #

(=\/=) :: PrimWithName name p wA wB -> PrimWithName name p wA wC -> EqCheck wB wC Source #

(=/\=) :: PrimWithName name p wA wC -> PrimWithName name p wB wC -> EqCheck wA wB Source #

(SignedId name, Eq2 prim, Commute prim) => Eq2 (RepoPatchV3 name prim) Source # 
Instance details

Defined in Darcs.Patch.V3.Core

Methods

unsafeCompare :: RepoPatchV3 name prim wA wB -> RepoPatchV3 name prim wC wD -> Bool Source #

(=\/=) :: RepoPatchV3 name prim wA wB -> RepoPatchV3 name prim wA wC -> EqCheck wB wC Source #

(=/\=) :: RepoPatchV3 name prim wA wC -> RepoPatchV3 name prim wB wC -> EqCheck wA wB Source #

(Eq2 a, Eq2 b) => Eq2 (a :> b) Source # 
Instance details

Defined in Darcs.Patch.Witnesses.Ordered

Methods

unsafeCompare :: (a :> b) wA wB -> (a :> b) wC wD -> Bool Source #

(=\/=) :: (a :> b) wA wB -> (a :> b) wA wC -> EqCheck wB wC Source #

(=/\=) :: (a :> b) wA wC -> (a :> b) wB wC -> EqCheck wA wB Source #

isIsEq :: EqCheck wA wB -> Bool Source #