From 54ae70a81e338fd05397ab22890b3ca36284be54 Mon Sep 17 00:00:00 2001 From: hallgren Date: Mon, 16 Feb 2015 15:05:06 +0000 Subject: Changes for compatibility with ghc-7.10-rc2 2 modules: Name clashes caused by Applicative-Monad change in Prelude 2 modules: Ambiguities caused by Foldable/Traversable in Prelude 2 modules: Backwards incompatible changes in time-1.5 for defaultTimeLocale 9 modules: {-# LANGUAGE FlexibleContexts #-} (because GHC checks inferred types now, in addition to explicitly given type signatures) Also silenced warnings about tab characters in source files. --- src/compiler/GF/Compile/Compute/Predef.hs | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'src/compiler/GF/Compile/Compute') diff --git a/src/compiler/GF/Compile/Compute/Predef.hs b/src/compiler/GF/Compile/Compute/Predef.hs index ba215ba30..768dc2e6b 100644 --- a/src/compiler/GF/Compile/Compute/Predef.hs +++ b/src/compiler/GF/Compile/Compute/Predef.hs @@ -93,7 +93,7 @@ delta f vs = Occurs -> fromNonExist vs PFalse (ap2 occurs) ToUpper -> fromNonExist vs NonExist (ap1 (map toUpper)) ToLower -> fromNonExist vs NonExist (ap1 (map toLower)) - IsUpper -> fromNonExist vs PFalse (ap1 (all isUpper)) + IsUpper -> fromNonExist vs PFalse (ap1 (all' isUpper)) Length -> fromNonExist vs (0::Int) (ap1 (length::String->Int)) Plus -> ap2 ((+)::Int->Int->Int) EqInt -> ap2 ((==)::Int->Int->Bool) @@ -131,8 +131,9 @@ delta f vs = tk i s = take (max 0 (length s - i)) s :: String dp i s = drop (max 0 (length s - i)) s :: String - occur s t = isInfixOf (s::String) t - occurs s t = any (`elem` t) (s::String) + occur s t = isInfixOf (s::String) (t::String) + occurs s t = any (`elem` (t::String)) (s::String) + all' = all :: (a->Bool) -> [a] -> Bool boolV b = VCApp (cPredef,if b then cPTrue else cPFalse) [] -- cgit v1.2.3