Closed ericgiovannini closed 4 years ago
@lastland has said this is a bug (https://github.com/antalsz/hs-to-coq/pull/159#discussion_r436303763). I am looking into fixing this now.
Currently, the relevant functions used in converting signatures have a ConversionMonad
constraint. I will try modifying these functions to have a LocalConvMonad
constraint instead, so that we can obtain the local edit information pertaining to the definition whose signature we are translating. Where necessary, I will use withCurrentDefinition
to switch from the global conversion monad to the local conversion monad.
Suppose we have
and our edit file looks like
The resulting Coq code will look like
Is this the intended behavior?