Skip to content

Commit f4f024b

Browse files
authored
Merge pull request #98 from haskellari/no-eq
Remove Eq requirement from ediffGolden
2 parents f25aa77 + 8d118b8 commit f4f024b

File tree

3 files changed

+8
-4
lines changed

3 files changed

+8
-4
lines changed

ChangeLog.md

+4
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
## 0.3.4
2+
3+
- Remove 'Eq a' requirement from 'ediffGolden'. The constraint wasn't used, as we only compare 'Expr' representations.
4+
15
## 0.3.3
26

37
- Change 'ediffGolden' so that parse errors in expected file don't cause the hard failure.

src/Data/TreeDiff/Golden.hs

+2-2
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ import qualified Text.PrettyPrint.ANSI.Leijen as WL
3737
-- for a proper example.
3838
--
3939
ediffGolden
40-
:: (Eq a, ToExpr a)
40+
:: ToExpr a
4141
=> (testName -> IO Expr -> IO Expr -> (Expr -> Expr -> IO (Maybe String)) -> (Expr -> IO ()) -> testTree) -- ^ 'goldenTest'
4242
-> testName -- ^ test name
4343
-> FilePath -- ^ path to "golden file"
@@ -51,7 +51,7 @@ ediffGolden impl testName fp x = ediffGolden1 impl' testName fp (\() -> x) where
5151
-- @since 0.3.2
5252
--
5353
ediffGolden1
54-
:: forall a arg testName testTree. (Eq a, ToExpr a)
54+
:: forall a arg testName testTree. ToExpr a
5555
=> (testName -> IO Expr -> (arg -> IO Expr) -> (Expr -> Expr -> IO (Maybe String)) -> (Expr -> IO ()) -> testTree) -- ^ 'goldenTest'
5656
-> testName -- ^ test name
5757
-> FilePath -- ^ path to "golden file"

tree-diff.cabal

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
cabal-version: 2.2
22
name: tree-diff
3-
version: 0.3.3
3+
version: 0.3.4
44
synopsis: Diffing of (expression) trees.
55
category: Data, Testing
66
description:
@@ -171,4 +171,4 @@ benchmark tree-diff-bench
171171
-- extra dependencies
172172
build-depends:
173173
, criterion ^>=1.6.3.0
174-
, Diff ^>=0.5
174+
, Diff ^>=1.0

0 commit comments

Comments
 (0)