[Pkg-haskell-commits] darcs: tools: hledger-lib patches
Clint Adams
clint at debian.org
Sat Dec 28 20:41:31 UTC 2013
Sat Dec 28 20:41:01 UTC 2013 Clint Adams <clint at debian.org>
* hledger-lib patches
A ./all-packages/patches/hledger-lib/
A ./all-packages/patches/hledger-lib/regex-tdfa
A ./all-packages/patches/hledger-lib/series
Sat Dec 28 20:41:01 UTC 2013 Clint Adams <clint at debian.org>
* hledger-lib patches
diff -rN -u old-tools/all-packages/patches/hledger-lib/regex-tdfa new-tools/all-packages/patches/hledger-lib/regex-tdfa
--- old-tools/all-packages/patches/hledger-lib/regex-tdfa 1970-01-01 00:00:00.000000000 +0000
+++ new-tools/all-packages/patches/hledger-lib/regex-tdfa 2013-12-28 20:41:31.714790817 +0000
@@ -0,0 +1,54 @@
+From 7f2ffe2e45e689a6f028f9dc23bee5dafa24f867 Mon Sep 17 00:00:00 2001
+From: Clint Adams <clint at debian.org>
+Date: Sat, 28 Dec 2013 13:31:58 -0500
+Subject: [PATCH] Use regex-tdfa instead of regex-compat-tdfa
+
+---
+ hledger-lib/Hledger/Utils.hs | 6 +++---
+ hledger-lib/hledger-lib.cabal | 4 ++--
+ 2 files changed, 5 insertions(+), 5 deletions(-)
+
+--- a/Hledger/Utils.hs
++++ b/Hledger/Utils.hs
+@@ -51,7 +51,7 @@
+ import Test.HUnit
+ import Text.ParserCombinators.Parsec
+ import Text.Printf
+-import Text.Regex
++import Text.Regex.TDFA
+ import Text.RegexPR
+ import Text.Show.Pretty
+ -- import qualified Data.Map as Map
+@@ -246,10 +246,10 @@
+
+ -- regex-compat (regex-posix) functions that perform better than regexpr.
+ regexMatchesRegexCompat :: String -> String -> Bool
+-regexMatchesRegexCompat r = isJust . matchRegex (mkRegex r)
++regexMatchesRegexCompat = flip (=~)
+
+ regexMatchesCIRegexCompat :: String -> String -> Bool
+-regexMatchesCIRegexCompat r = isJust . matchRegex (mkRegexWithOpts r True False)
++regexMatchesCIRegexCompat r = match (makeRegexOpts defaultCompOpt { multiline = True, caseSensitive = False, newSyntax = True } defaultExecOpt r)
+
+ -- lists
+
+--- a/hledger-lib.cabal
++++ b/hledger-lib.cabal
+@@ -68,7 +68,7 @@
+ ,old-time
+ ,parsec
+ ,pretty-show
+- ,regex-compat-tdfa == 0.95.*
++ ,regex-tdfa
+ ,regexpr >= 0.5.1
+ ,safe >= 0.2
+ ,split >= 0.1 && < 0.3
+@@ -100,7 +100,7 @@
+ , old-time
+ , parsec
+ , pretty-show
+- , regex-compat-tdfa
++ , regex-tdfa
+ , regexpr
+ , safe
+ , split
diff -rN -u old-tools/all-packages/patches/hledger-lib/series new-tools/all-packages/patches/hledger-lib/series
--- old-tools/all-packages/patches/hledger-lib/series 1970-01-01 00:00:00.000000000 +0000
+++ new-tools/all-packages/patches/hledger-lib/series 2013-12-28 20:41:31.714790817 +0000
@@ -0,0 +1 @@
+regex-tdfa
More information about the Pkg-haskell-commits
mailing list