Open Abhiroop opened 3 years ago
A possible fix from @Rewbert
In Renaming.hs
DTypeSig id t -> do
b <- isRenamed id
if b
then do ds' <- renameDef ds
return $ DTypeSig id t : ds'
else do id' <- fresh
inEnv (id, id') (do ds' <- renameDef ds
return $ DTypeSig id' t : ds')
and in Desugar.hs
Line #114 and and #115
desugarMain m [AST.DTypeSig _ _, def] = desugarMain m [def]
The
main
function is eliminated and we get: