./textproc/hs-Diff, Diff algorithm in pure Haskell

[ CVSweb ] [ Homepage ] [ RSS ] [ Required by ] [ Add to tracker ]


Branch: CURRENT, Version: 1.0.2nb1, Package name: hs-Diff-1.0.2nb1, Maintainer: pkgsrc-users

Implementation of the standard diff algorithm in Haskell.

Time complexity is O(ND) (input length * number of differences). Space
complexity is O(D^2). Includes utilities for pretty printing.


Required to run:
[lang/ghc94]

Master sites:

Filesize: 10.68 KB

Version history: (Expand)


CVS history: (Expand)


   2025-02-02 14:06:08 by Masatake Daimon | Files touched by this commit (1173)
Log message:
Bump all Haskell packages after switching the default compiler.
   2025-01-31 03:20:14 by Masatake Daimon | Files touched by this commit (5) | Package updated
Log message:
textproc/hs-Diff: update to Diff-1.0.2

# 1.0.2

  - Output correct format when an input file is empty, e.g. `@@ --0,0 +1,3 @@`.

# 1.0.1.1

  - Require `base >= 4.11` (GHC 8.4).

# 1.0

  - Add Unix diff style annotations to output of `prettyContextDiff`,
    e.g `@@ -1,5 +1,4 @@`.  This required three changes to the
    signature of `getContextDiff` due to the addition of a wrapper type
    `Numbered`, which enumerates the elements of the input list.

  - Signature change 1: The element pretty printer type changes from
    `(a -> Doc)` to `(Numbered a -> Doc)`.  An unnumber function is
    provided so that the old behavior can be obtained by changing that
    argument from `pretty` to `(pretty . unnumber)`

  - Signature change 2: The result type of getContextDiff changes from
    `ContextDiff a` to `ContextDiff (Numbered a)`.  A function
    `unNumberContextDiff` is provided to convert the result back to
    the old type.

  - Signature change 3: the context argument is now `Maybe Int` rather
    than `Int`, reflecting the change made to `getContextDiffNew` in 0.5.

  - A `prettyContextDiffOld` function is provided to get the old
    style output.

  - The old broken version of getContextDiffOld is removed.

  - Document the behavior of `groupBy'`.

# 0.5

  - Bring space complexity down to D^2 (Bodigrim).
  - Add `Bifunctor` instance (Jonathan King).  Requires `base` >= 4.8.
  - Fix for the grouped context diff.  It was omitting all trailing contexts.
  - Allow unlimited number of context elements (`getContextDiffNew`).

# 0.4

  - Generalize `Diff a` to `PolyDiff a b`.
    `Diff` has been replaced with a specialized synonym `type Diff a = PolyDiff a a`,
    but it's still not backward compatible if you imported `Diff(..)`.
   2024-05-09 03:32:57 by Masatake Daimon | Files touched by this commit (1137)
Log message:
Recursive revbump after changing the default Haskell compiler
   2024-04-28 22:58:52 by Masatake Daimon | Files touched by this commit (1)
Log message:
textproc/hs-Diff: Fix build with GHC 9.8

This breaks build with the currently default GHC 9.6. Please bear with me
until I switch the default compiler.
   2023-11-02 07:37:49 by Masatake Daimon | Files touched by this commit (1141)
Log message:
Revbump all Haskell after updating lang/ghc96
   2023-10-26 08:53:51 by Masatake Daimon | Files touched by this commit (4)
Log message:
textproc/hs-Diff: Update to 0.5

No change log is provided by the upstream.
   2023-10-09 06:55:01 by Masatake Daimon | Files touched by this commit (988)
Log message:
Bump Haskell packages after updating lang/ghc94
   2022-02-26 04:58:36 by Masatake Daimon | Files touched by this commit (872)
Log message:
Bump all Haskell packages after enabling "split sections" in mk/haskell.mk