import FunDeps
import TcMType
import TcType
+import DsUtils
import Type
import TypeRep
import Class
import Coercion
import HscTypes
import CoreFVs
-import DataCon
import Id
import Name
import NameSet
-import Literal
import Var ( Var, TyVar )
import qualified Var
import VarEnv
import VarSet
-import TysWiredIn
import PrelNames
import BasicTypes
import SrcLoc
import Unique
import Outputable
import Data.List
-import TypeRep
-import Class
import Control.Monad
\end{code}
in
mkForAllTys tvs $
mkPhiTy (map dictPred givens) $
- if isSingleton dict_wanteds then
- instType (head dict_wanteds)
- else
- mkTupleTy Boxed (length dict_wanteds) (map instType dict_wanteds)
+ mkBigCoreTupTy (map instType dict_wanteds)
dictPred :: Inst -> TcPredType
dictPred (Dict {tci_pred = pred}) = pred
lookupSimpleInst (LitInst { tci_lit = lit@OverLit { ol_val = lit_val
, ol_rebindable = rebindable }
, tci_ty = ty, tci_loc = iloc})
-#ifdef DEBUG
- | rebindable = panic "lookupSimpleInst" -- A LitInst invariant
-#endif
+ | debugIsOn && rebindable = panic "lookupSimpleInst" -- A LitInst invariant
| Just witness <- shortCutLit lit_val ty
= do { let lit' = lit { ol_witness = witness, ol_type = ty }
; return (GenInst [] (L loc (HsOverLit lit'))) }