diff --git a/inch.cabal b/inch.cabal
--- a/inch.cabal
+++ b/inch.cabal
@@ -1,7 +1,7 @@
 Name:                inch
-Version:             0.1.0
+Version:             0.2.0
 Synopsis:            A type-checker for Haskell with integer constraints
-Description:         
+Description:
     Inch is a type-checker for a subset of Haskell (plus some GHC
     extensions) with the addition of integer constraints. After
     successfully type-checking a source file, it outputs an
@@ -38,13 +38,13 @@
   hs-source-dirs:    src
   Main-is:           Language/Inch/Main.lhs
   Build-depends:     base == 4.*,
-                         IndentParser == 0.2.*,
-                         parsec == 3.1.*,
+                         IndentParser > 0.2 && < 0.3,
+                         parsec > 3.1  && < 3.5,
                          presburger == 0.4.*,
-                         pretty == 1.*,
-                         mtl == 2.0.*,
-                         containers == 0.4.*,
-                         filepath == 1.2.*
+                         pretty >= 1.0 && < 2,
+                         mtl > 2.0  && < 2.3,
+                         containers > 0.4  && < 0.6,
+                         filepath > 1.2  && < 1.4
   Other-modules:     Language.Inch.BwdFwd,
                          Language.Inch.Check,
                          Language.Inch.Context
@@ -63,21 +63,22 @@
                          Language.Inch.TyNum
                          Language.Inch.TypeCheck
                          Language.Inch.Type
-                         Language.Inch.Unify         
-  
+                         Language.Inch.Unify
+
 Test-Suite test-inch
     type:            exitcode-stdio-1.0
     hs-source-dirs:  src tests
     main-is:         Main.lhs
     build-depends:   base == 4.*,
-                         IndentParser == 0.2.*,
-                         parsec == 3.1.*,
+                         IndentParser > 0.2 && < 0.3,
+                         parsec > 3.1  && < 3.5,
                          presburger == 0.4.*,
-                         pretty == 1.*,
-                         mtl == 2.0.*,
-                         containers == 0.4.*,
-                         filepath == 1.2.*,
-                         directory == 1.1.*
+                         pretty >= 1.0 && < 2,
+                         mtl > 2.0  && < 2.3,
+                         containers > 0.4  && < 0.6,
+                         filepath > 1.2  && < 1.4,
+                         directory > 1.1 && < 1.3
+
 
 source-repository head
   type:     git
diff --git a/src/Language/Inch/Context.lhs b/src/Language/Inch/Context.lhs
--- a/src/Language/Inch/Context.lhs
+++ b/src/Language/Inch/Context.lhs
@@ -7,7 +7,7 @@
 > import Control.Applicative
 > import Control.Monad.Error
 > import Control.Monad.State
-> import Control.Monad.Writer hiding (All)
+> import Control.Monad.Writer hiding (All, (<>))
 > import qualified Data.Map as Map
 > import Data.Map (Map)
 > import Data.Foldable
diff --git a/src/Language/Inch/File.lhs b/src/Language/Inch/File.lhs
--- a/src/Language/Inch/File.lhs
+++ b/src/Language/Inch/File.lhs
@@ -2,8 +2,8 @@
 
 > module Language.Inch.File where
 
-> import Prelude hiding (catch)
-> import Control.Exception
+> import Prelude 
+> import qualified Control.Exception as E
 > import Control.Monad.State
 > import System.Exit
 > import System.FilePath
@@ -52,8 +52,8 @@
 
 > readImport :: FilePath -> Import -> IO [STopDeclaration]
 > readImport dir im = do
->     s <- catch (readFile (combine dir inchFile)) $ \ (_ :: IOException) ->
->              catch (readFile =<< getDataFileName inchFile) $ \ (_ :: IOException) ->
+>     s <- E.catch (readFile (combine dir inchFile)) $ \ (_ :: E.IOException) ->
+>              E.catch (readFile =<< getDataFileName inchFile) $ \ (_ :: E.IOException) ->
 >                  hPutStrLn stderr ("Could not load " ++ inchFile) >> return ""
 >     case parseInterface inchFile s of
 >         Right ds  -> return $ filter (included . topDeclName) ds
diff --git a/src/Language/Inch/Main.lhs b/src/Language/Inch/Main.lhs
--- a/src/Language/Inch/Main.lhs
+++ b/src/Language/Inch/Main.lhs
@@ -2,7 +2,7 @@
 
 > module Main where
 
-> import Prelude hiding (catch)
+> import Prelude
 > import System.Environment
 > import System.FilePath
 
diff --git a/src/Language/Inch/ModuleSyntax.lhs b/src/Language/Inch/ModuleSyntax.lhs
--- a/src/Language/Inch/ModuleSyntax.lhs
+++ b/src/Language/Inch/ModuleSyntax.lhs
@@ -1,5 +1,6 @@
 > {-# LANGUAGE StandaloneDeriving, TypeOperators, GADTs,
->              FlexibleInstances, MultiParamTypeClasses, TypeFamilies #-}
+>              FlexibleInstances, MultiParamTypeClasses,
+>              TypeFamilies, AllowAmbiguousTypes #-}
 
 > module Language.Inch.ModuleSyntax where
 
diff --git a/src/Language/Inch/Syntax.lhs b/src/Language/Inch/Syntax.lhs
--- a/src/Language/Inch/Syntax.lhs
+++ b/src/Language/Inch/Syntax.lhs
@@ -3,7 +3,7 @@
 >              StandaloneDeriving, TypeFamilies, RankNTypes,
 >              ImpredicativeTypes, FlexibleContexts,
 >              MultiParamTypeClasses, EmptyDataDecls,
->              UndecidableInstances #-}
+>              UndecidableInstances, AllowAmbiguousTypes #-}
 
 > module Language.Inch.Syntax where
 
diff --git a/src/Language/Inch/TypeCheck.lhs b/src/Language/Inch/TypeCheck.lhs
--- a/src/Language/Inch/TypeCheck.lhs
+++ b/src/Language/Inch/TypeCheck.lhs
@@ -134,8 +134,10 @@
 
 >     solveForLots :: Var () KNum -> [Type KConstraint] -> Maybe NormalNum
 >     solveForLots a = getFirst . foldMap (First . maybeSolveFor a) . mapMaybe f
->       where  f (TyComp EL `TyApp` m `TyApp` n)  = Just (normaliseNum (m - n))
->              f _           = Nothing
+>       where
+>         f :: Type k -> Maybe NormalNum
+>         f (TyComp EL `TyApp` m `TyApp` n)  = Just (normaliseNum (m - n))
+>         f _           = Nothing
 
 
 > subsCheck :: Sigma -> Sigma -> Contextual ()
