[darcs-devel] [patch1730] add RepoPatchV3 aka camp conflictors, now with almost complete integration
Ganesh Sittampalam
bugs at darcs.net
Fri Jun 14 13:56:50 UTC 2019
Ganesh Sittampalam <ganesh at earth.li> added the comment:
> * add RepoPatchV3 aka camp conflictors
> -- | Signed patch identity.
> -- The 'SHA1' hash of the non-inverted meta data ('PatchInfo')
plus
> -- an 'Int' for the sequence number within the named patch.
> -- The 'Int' gets inverted together with the patch.
> data PrimPatchId = PrimPatchId !Int !SHA1
> deriving (Eq, Ord, Show)
> instance SignedId PrimPatchId where
> positiveId (PrimPatchId i _) = i > 0
> invertId (PrimPatchId i h) = PrimPatchId (- i) h
Is it illegal for the Int to be 0? If so this should be documented
and ideally tested. (I haven't read a lot of the rest of the
relevant code yet, so this might already be tested.)
__________________________________
Darcs bug tracker <bugs at darcs.net>
<http://bugs.darcs.net/patch1730>
__________________________________
More information about the darcs-devel
mailing list