diff --git a/src/compiler/GF/Compile/TypeCheck/Concrete.hs b/src/compiler/GF/Compile/TypeCheck/Concrete.hs index fc2e3331a..0727ffe14 100644 --- a/src/compiler/GF/Compile/TypeCheck/Concrete.hs +++ b/src/compiler/GF/Compile/TypeCheck/Concrete.hs @@ -182,9 +182,9 @@ inferLType gr g trm = case trm of K s -> let trm' = case words s of - [] -> Empty - [w] -> K w - ws -> foldr C Empty (map K ws) + [] -> Empty + [w] -> K w + (w:ws) -> foldl (\t -> C t . K) (K w) ws in return (trm', typeStr) EInt i -> return (trm, typeInt)