summaryrefslogtreecommitdiff
path: root/bindisttest
diff options
context:
space:
mode:
authorsimonpj@microsoft.com <unknown>2007-09-05 17:07:30 +0000
committersimonpj@microsoft.com <unknown>2007-09-05 17:07:30 +0000
commit25f84fa7e4b84c3db5ba745a7881c009b778e0b1 (patch)
tree1b00125874ff77333b217b7a39c289e89e759951 /bindisttest
parentd9236c265896d65ae4f1d4f4a240d8c0ffbce6f3 (diff)
downloadhaskell-25f84fa7e4b84c3db5ba745a7881c009b778e0b1.tar.gz
Refactor, improve, and document the deriving mechanism
This patch does a fairly major clean-up of the code that implements 'deriving. * The big changes are in TcDeriv, which is dramatically cleaned up. In particular, there is a clear split into a) inference of instance contexts for deriving clauses b) generation of the derived code, given a context Step (a) is skipped for standalone instance decls, which have an explicitly provided context. * The handling of "taggery", which is cooperative between TcDeriv and TcGenDeriv, is cleaned up a lot * I have added documentation for standalone deriving (which was previously wrong). * The Haskell report is vague on exactly when a deriving clause should succeed. Prodded by Conal I have loosened the rules slightly, thereyb making drv015 work again, and documented the rules in the user manual. I believe this patch validates ok (once I've update the test suite) and can go into the 6.8 branch.
Diffstat (limited to 'bindisttest')
0 files changed, 0 insertions, 0 deletions