import TcType ( TcType, TcTyVar, TcTyVarSet, tcInstSigTyVars,
zonkSigTyVar, tcInstSigTcType
)
-import PragmaInfo ( PragmaInfo(..) )
-
+import FieldLabel ( firstFieldLabelTag )
import Bag ( unionManyBags )
import Class ( mkClass, classBigSig, Class )
import CmdLineOpts ( opt_GlasgowExts )
+import MkId ( mkDataCon, mkSuperDictSelId,
+ mkMethodSelId, mkDefaultMethodId
+ )
import Id ( Id, StrictnessMark(..),
- mkSuperDictSelId, mkMethodSelId,
- mkDefaultMethodId, getIdUnfolding, mkDataCon,
- idType
+ getIdUnfolding, idType
)
import CoreUnfold ( getUnfoldingTemplate )
import IdInfo
-- import TcPragmas ( tcGenPragmas, tcClassOpPragmas )
tcGenPragmas ty id ps = returnNF_Tc noIdInfo
-tcClassOpPragmas ty sel def spec ps = returnNF_Tc (noIdInfo `setSpecInfo` spec,
+tcClassOpPragmas ty sel def spec ps = returnNF_Tc (spec `setSpecInfo` noIdInfo,
noIdInfo)
\end{code}
-- D_sc1, D_sc2
-- (We used to call them D_C, but now we can have two different
-- superclasses both called C!)
- mapTc mk_super_id (sc_theta `zip` [1..]) `thenTc` \ sc_sel_ids ->
+ mapTc mk_super_id (sc_theta `zip` [firstFieldLabelTag..]) `thenTc` \ sc_sel_ids ->
-- Done
returnTc (sc_theta, sc_tys, sc_sel_ids)
tcExtendGlobalTyVars inst_tyvars (
tcAddErrCtxt (methodCtxt sel_id) $
tcBindWithSigs NotTopLevel [bndr_name] meth_bind [sig_info]
- NonRecursive (\_ -> NoPragmaInfo)
+ NonRecursive (\_ -> noIdInfo)
) `thenTc` \ (binds, insts, _) ->
-- Now check that the instance type variables