@@ -34,7 +34,7 @@ compile target f tm
3434 hdrs <- getHdrs
3535 let defs = defsIn ++ [(MN 0 "runMain", maindef)]
3636 -- iputStrLn $ showSep "\n" (map show defs)
37− let (nexttag, tagged) = addTags 0 (liftAll defs)
37+ let (nexttag, tagged) = addTags 65536 (liftAll defs)
3838 let ctxtIn = addAlist tagged emptyContext
3939 let defuns = defunctionalise nexttag ctxtIn
4040 -- iputStrLn $ showSep "\n" (map show (toAlist defuns))
@@ -100,7 +100,7 @@ mkLDecl n (Function tm _) = do e <- ir tm
100100 return (declArgs [] n e)
101101mkLDecl n (CaseOp _ _ pats _ _ args sc) = do e <- ir (args, sc)
102102 return (declArgs [] n e)
103−mkLDecl n (TyDecl (DCon t a) _) = return $ LConstructor n (-1) a
103+mkLDecl n (TyDecl (DCon t a) _) = return $ LConstructor n t a
104104mkLDecl n (TyDecl (TCon t a) _) = return $ LConstructor n (-1) a
105105mkLDecl n _ = return (LFun n [] (LError ("Impossible declaration " ++ show n)))
106106