diff options
| author | hallgren <hallgren@chalmers.se> | 2015-02-16 15:05:06 +0000 |
|---|---|---|
| committer | hallgren <hallgren@chalmers.se> | 2015-02-16 15:05:06 +0000 |
| commit | 54ae70a81e338fd05397ab22890b3ca36284be54 (patch) | |
| tree | c6757f0c7f0d90a39329a2180ad1df33a99e384b /src/compiler/GF/Compile/Compute | |
| parent | 2b8fe8ea7a4f40445889b80bd7f737d0078e7598 (diff) | |
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.
Diffstat (limited to 'src/compiler/GF/Compile/Compute')
| -rw-r--r-- | src/compiler/GF/Compile/Compute/Predef.hs | 7 |
1 files changed, 4 insertions, 3 deletions
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) [] |
