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

Darcs.Patch.PatchInfoAnd

Synopsis

Documentation

data Hopefully a wX wY Source #

Hopefully p C (x y) is Either String (p C (x y)) in a form adapted to darcs patches. The C (x y) represents the type witness for the patch that should be there. The Hopefully type just tells whether we expect the patch to be hashed or not, and SimpleHopefully does the real work of emulating Either. Hopefully sh represents an expected unhashed patch, and Hashed hash sh represents an expected hashed patch with its hash.

Instances

Instances details
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 #

Show (a wX wY) => Show (Hopefully a wX wY) Source # 
Instance details

Defined in Darcs.Patch.PatchInfoAnd

Methods

showsPrec :: Int -> Hopefully a wX wY -> ShowS #

show :: Hopefully a wX wY -> String #

showList :: [Hopefully a wX wY] -> ShowS #

data PatchInfoAndG p wA wB Source #

PatchInfoAnd p wA wB represents a hope we have to get a patch through its info. We're not sure we have the patch, but we know its info.

Instances

Instances details
Apply p => Apply (PatchInfoAndG p) Source # 
Instance details

Defined in Darcs.Patch.PatchInfoAnd

Associated Types

type ApplyState (PatchInfoAndG p) :: (Type -> Type) -> Type Source #

Methods

apply :: ApplyMonad (ApplyState (PatchInfoAndG p)) m => PatchInfoAndG p wX wY -> m () Source #

unapply :: ApplyMonad (ApplyState (PatchInfoAndG p)) m => PatchInfoAndG p wX wY -> m () Source #

(PatchId p ~ PatchInfo, Commute p) => Commute (PatchInfoAndG p) Source # 
Instance details

Defined in Darcs.Patch.PatchInfoAnd

(Commute p, Conflict p, Summary p, PrimPatchBase p, PatchListFormat p, ShowPatch p) => Conflict (PatchInfoAnd p) Source # 
Instance details

Defined in Darcs.Patch.PatchInfoAnd

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

Defined in Darcs.Patch.PatchInfoAnd

Methods

patchDebugDummy :: PatchInfoAndG p wX wY -> () Source #

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

Defined in Darcs.Patch.PatchInfoAnd

Methods

effect :: PatchInfoAndG p wX wY -> FL (PrimOf (PatchInfoAndG p)) wX wY Source #

IsHunk (PatchInfoAndG p) Source # 
Instance details

Defined in Darcs.Patch.PatchInfoAnd

PatchListFormat (PatchInfoAndG p) Source # 
Instance details

Defined in Darcs.Patch.PatchInfoAnd

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

Defined in Darcs.Patch.PatchInfoAnd

Associated Types

type PrimOf (PatchInfoAndG p) :: Type -> Type -> Type Source #

Ident (PatchInfoAndG p) Source # 
Instance details

Defined in Darcs.Patch.PatchInfoAnd

Methods

ident :: PatchInfoAndG p wX wY -> PatchId (PatchInfoAndG p) Source #

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

Defined in Darcs.Patch.PatchInfoAnd

(PatchId p ~ PatchInfo, CleanMerge p) => CleanMerge (PatchInfoAndG p) Source # 
Instance details

Defined in Darcs.Patch.PatchInfoAnd

(PatchId p ~ PatchInfo, Merge p) => Merge (PatchInfoAndG p) Source # 
Instance details

Defined in Darcs.Patch.PatchInfoAnd

(ReadPatch p, Ident p, PatchId p ~ PatchInfo) => ReadPatch (PatchInfoAndG p) Source # 
Instance details

Defined in Darcs.Patch.PatchInfoAnd

RepairToFL p => Repair (PatchInfoAnd p) Source # 
Instance details

Defined in Darcs.Patch.PatchInfoAnd

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

Defined in Darcs.Patch.PatchInfoAnd

(Summary p, PatchListFormat p, ShowPatch p) => ShowPatch (PatchInfoAndG p) Source # 
Instance details

Defined in Darcs.Patch.PatchInfoAnd

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

Defined in Darcs.Patch.PatchInfoAnd

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 #

Show2 p => Show2 (PatchInfoAnd p) Source # 
Instance details

Defined in Darcs.Patch.PatchInfoAnd

Methods

showDict2 :: ShowDict (PatchInfoAnd p wX wY) Source #

Show2 p => Show1 (PatchInfoAnd p wX) Source # 
Instance details

Defined in Darcs.Patch.PatchInfoAnd

Methods

showDict1 :: Dict (Show (PatchInfoAnd p wX wX0)) Source #

Show (p wA wB) => Show (PatchInfoAndG p wA wB) Source # 
Instance details

Defined in Darcs.Patch.PatchInfoAnd

Methods

showsPrec :: Int -> PatchInfoAndG p wA wB -> ShowS #

show :: PatchInfoAndG p wA wB -> String #

showList :: [PatchInfoAndG p wA wB] -> ShowS #

type ApplyState (PatchInfoAndG p) Source # 
Instance details

Defined in Darcs.Patch.PatchInfoAnd

type PrimOf (PatchInfoAndG p) Source # 
Instance details

Defined in Darcs.Patch.PatchInfoAnd

type PatchId (PatchInfoAndG p) Source # 
Instance details

Defined in Darcs.Patch.PatchInfoAnd

piap :: PatchInfo -> p wA wB -> PatchInfoAndG p wA wB Source #

piap i p creates a PatchInfoAnd containing p with info i.

n2pia :: (Ident p, PatchId p ~ PatchInfo) => p wX wY -> PatchInfoAndG p wX wY Source #

n2pia creates a PatchInfoAnd representing a Named patch.

fmapPIAP :: (p wX wY -> q wX wY) -> PatchInfoAndG p wX wY -> PatchInfoAndG q wX wY Source #

fmapFLPIAP :: (FL p wX wY -> FL q wX wY) -> PatchInfoAnd p wX wY -> PatchInfoAnd q wX wY Source #

hopefully :: PatchInfoAndG p wA wB -> p wA wB Source #

hopefully hp tries to get a patch from a PatchInfoAnd value. If it fails, it outputs an error "failed to read patch: <description of the patch>". We get the description of the patch from the info part of hp

hopefullyM :: PatchInfoAndG p wA wB -> Maybe (p wA wB) Source #

Return Just the patch content or Nothing if it is unavailable.

actually :: a wX wY -> Hopefully a wX wY Source #

patchDesc :: forall p wX wY. PatchInfoAnd p wX wY -> String Source #