darcs-2.16.5: a distributed, interactive, smart revision control system

Safe Haskell | Safe-Inferred
Language | Haskell2010

Darcs.Patch.Named.Wrapped

Synopsis

- data WrappedNamed (rt :: RepoType) p wX wY where
  - NormalP :: !(Named p wX wY) -> WrappedNamed rt p wX wY
  - RebaseP :: (PrimPatchBase p, FromPrim p, Effect p) => !PatchInfo -> !(Suspended p wX wX) -> WrappedNamed ('RepoType 'IsRebase) p wX wX
- fromRebasing :: WrappedNamed rt p wX wY -> Named p wX wY

# Documentation

data WrappedNamed (rt :: RepoType) p wX wY where #

A patch that lives in a repository where an old-style rebase is in progress. Such a repository will consist of `Normal` patches along with exactly one `Suspended` patch.

It is here only so that we can upgrade an old-style rebase.

`NormalP` represents a normal patch within a respository where a rebase is in progress. `NormalP p` is given the same on-disk representation as `p`, so a repository can be switched into and out of rebasing mode simply by adding or removing a `RebaseP` patch and setting the appropriate format flag.

Note that the witnesses are such that the `RebaseP` patch has no effect on the context of the rest of the repository; in a sense the patches within it are dangling off to one side from the main repository.

Constructors

NormalP :: !(Named p wX wY) -> WrappedNamed rt p wX wY |
RebaseP :: (PrimPatchBase p, FromPrim p, Effect p) => !PatchInfo -> !(Suspended p wX wX) -> WrappedNamed ('RepoType 'IsRebase) p wX wX |

#### Instances

Instances details

Apply p => Apply (WrappedNamed rt p) # |
Instance details Defined in Darcs.Patch.Named.Wrapped Associated Types type ApplyState (WrappedNamed rt p) :: (Type -> Type) -> Type # Methods apply :: ApplyMonad (ApplyState (WrappedNamed rt p)) m => WrappedNamed rt p wX wY -> m () # unapply :: ApplyMonad (ApplyState (WrappedNamed rt p)) m => WrappedNamed rt p wX wY -> m () #
Commute p => Commute (WrappedNamed rt p) # |
Instance details Defined in Darcs.Patch.Named.Wrapped Methods commute :: (WrappedNamed rt p :> WrappedNamed rt p) wX wY -> Maybe ((WrappedNamed rt p :> WrappedNamed rt p) wX wY) #
PatchListFormat (WrappedNamed rt p) # |
Instance details Defined in Darcs.Patch.Named.Wrapped Methods patchListFormat :: ListFormat (WrappedNamed rt p) #
PrimPatchBase p => PrimPatchBase (WrappedNamed rt p) # |
Instance details Defined in Darcs.Patch.Named.Wrapped Associated Types type PrimOf (WrappedNamed rt p) :: Type -> Type -> Type #
Ident (WrappedNamed rt p) # |
Instance details Defined in Darcs.Patch.Named.Wrapped Methods ident :: WrappedNamed rt p wX wY -> PatchId (WrappedNamed rt p) #
(ReadPatch p, PrimPatchBase p, FromPrim p, Effect p, PatchListFormat p, RepoPatch p, IsRepoType rt) => ReadPatch (WrappedNamed rt p) # |
Instance details Defined in Darcs.Patch.Named.Wrapped Methods readPatch' :: Parser (Sealed (WrappedNamed rt p wX)) #
(ShowPatchBasic p, PatchListFormat p) => ShowPatchBasic (WrappedNamed rt p) # |
Instance details Defined in Darcs.Patch.Named.Wrapped Methods showPatch :: ShowPatchFor -> WrappedNamed rt p wX wY -> Doc #
Show2 p => Show2 (WrappedNamed rt p) # |
Instance details Defined in Darcs.Patch.Named.Wrapped Methods showDict2 :: ShowDict (WrappedNamed rt p wX wY) #
Show2 p => Show1 (WrappedNamed rt p wX) # |
Instance details Defined in Darcs.Patch.Named.Wrapped Methods showDict1 :: Dict (Show (WrappedNamed rt p wX wX0)) #
Show2 p => Show (WrappedNamed rt p wX wY) # |
Instance details Defined in Darcs.Patch.Named.Wrapped Methods showsPrec :: Int -> WrappedNamed rt p wX wY -> ShowS # show :: WrappedNamed rt p wX wY -> String # showList :: [WrappedNamed rt p wX wY] -> ShowS #
type ApplyState (WrappedNamed rt p) # |
Instance details Defined in Darcs.Patch.Named.Wrapped type ApplyState (WrappedNamed rt p) = ApplyState p
type PrimOf (WrappedNamed rt p) # |
Instance details Defined in Darcs.Patch.Named.Wrapped type PrimOf (WrappedNamed rt p) = PrimOf p
type PatchId (WrappedNamed rt p) # |
Instance details Defined in Darcs.Patch.Named.Wrapped type PatchId (WrappedNamed rt p) = PatchInfo

fromRebasing :: WrappedNamed rt p wX wY -> Named p wX wY #