Fix a long-standing bug in CSE
authorSimon Peyton Jones <simonpj@microsoft.com>
Thu, 8 Dec 2016 23:59:47 +0000 (23:59 +0000)
committerSimon Peyton Jones <simonpj@microsoft.com>
Mon, 12 Dec 2016 16:38:42 +0000 (16:38 +0000)
commitd03dd23744799f7df1a73df26d7833887d8e97e9
tree0f7aff99c02a4ef1a48d0c6dbc0629dda7de2d90
parent6720376500c33947fe196b68fe54f5e448376c5d
Fix a long-standing bug in CSE

I had the environments wrong so that CSE could mis-clone
an expression, if the uniques just happened to be badly
arranged.  It's hard to trigger the bug, so I can't make
a reliable test case.

Happily the fix is easy.
compiler/simplCore/CSE.hs