From fa1678c644962e21e13da4bfcb516c68233adaf9 Mon Sep 17 00:00:00 2001 From: Viktor Dukhovni Date: Wed, 27 May 2020 03:58:39 -0400 Subject: [PATCH] GHC 8.12 compatibility Infix "!" now requires whitespace to disambiguate from BangPatterns (except in "tight" a!b syntax). --- src/Text/Regex/Base/Context.hs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Text/Regex/Base/Context.hs b/src/Text/Regex/Base/Context.hs index 1067f73..60e95ad 100644 --- a/src/Text/Regex/Base/Context.hs +++ b/src/Text/Regex/Base/Context.hs @@ -300,8 +300,8 @@ instance (RegexLike a b) => RegexContext a b Int where -- ** Instances based on matchOnce,matchOnceText instance (RegexLike a b) => RegexContext a b (MatchOffset,MatchLength) where - match r s = maybe (-1,0) (!0) (matchOnce r s) - matchM r s = maybe regexFailed (return.(!0)) (matchOnce r s) + match r s = maybe (-1,0) (! 0) (matchOnce r s) + matchM r s = maybe regexFailed (return.(! 0)) (matchOnce r s) instance (RegexLike a b) => RegexContext a b (MatchResult b) where match r s = maybe (MR {mrBefore = s,mrMatch = empty,mrAfter = empty