@@ -51,12 +51,12 @@ namePis i (IBindHere fc m ty) = IBindHere fc m (namePis i ty)
5151namePis i ty = ty
5252
5353getSig : ImpDecl -> Maybe Signature
54- getSig (IClaim (MkWithData _ $ MkIClaimData c _ opts ( MkImpTy fc n ty) ))
54+ getSig (IClaim (MkWithData _ $ MkIClaimData c _ opts ty ))
5555 = Just $ MkSignature { count = c
5656 , flags = opts
57- , name = n
57+ , name = ty . tyName
5858 , isData = False
59- , type = namePis 0 ty
59+ , type = namePis 0 ty. val
6060 }
6161getSig (IData _ _ _ (MkImpLater fc n ty))
6262 = Just $ MkSignature { count = erased
@@ -121,7 +121,7 @@ mkIfaceData {vars} ifc def_vis env constraints n conName ps dets meths
121121 conty = mkTy vfc Implicit (map jname ps) $
122122 mkTy vfc AutoImplicit (map bhere constraints) $
123123 mkTy vfc Explicit (map bname meths) retty
124- con = MkImpTy vfc ( NoFC conName) ! (bindTypeNames ifc [] (pNames ++ map fst meths ++ toList vars) conty)
124+ con = Mk [ vfc, NoFC conName] ! (bindTypeNames ifc [] (pNames ++ map fst meths ++ toList vars) conty)
125125 bound = pNames ++ map fst meths ++ toList vars in
126126
127127 pure $ IData vfc def_vis Nothing {- ?? -}
@@ -189,7 +189,7 @@ getMethToplevel {vars} env vis iname cname constraints allmeths bindNames params
189189 cn <- traverse inCurrentNS sig. name
190190 let tydecl = IClaim (MkFCVal vfc $ MkIClaimData sig. count vis (if sig. isData then [Inline , Invertible ]
191191 else [Inline ])
192- (MkImpTy vfc cn ty_imp))
192+ (Mk [ vfc, cn] ty_imp))
193193 let conapp = apply (IVar vfc cname) (map (IBindVar EmptyFC ) bindNames)
194194 let argns = getExplicitArgs 0 sig. type
195195 -- eta expand the RHS so that we put implicits in the right place
@@ -250,7 +250,7 @@ getConstraintHint {vars} fc env vis iname cname constraints meths params (cn, co
250250 (UN (Basic $ " __" ++ show iname ++ " _" ++ show con))
251251
252252 let tydecl = IClaim (MkFCVal fc $ MkIClaimData top vis [Inline , Hint False ]
253- (MkImpTy EmptyFC ( NoFC hintname) ty_imp))
253+ (Mk [ EmptyFC , NoFC hintname] ty_imp))
254254
255255 let conapp = apply (impsBind (IVar fc cname) constraints)
256256 (map (const (Implicit fc True )) meths)
@@ -436,7 +436,7 @@ elabInterface {vars} ifc def_vis env nest constraints iname params dets mcon bod
436436
437437 let dtydecl = IClaim $ MkFCVal vdfc
438438 $ MkIClaimData rig (collapseDefault def_vis) []
439- $ MkImpTy EmptyFC ( NoFC dn) dty_imp
439+ $ Mk [ EmptyFC , NoFC dn] dty_imp
440440
441441 processDecl [] nest env dtydecl
442442
0 commit comments