Fix erroneous float in CoreOpt
authorSimon Peyton Jones <simonpj@microsoft.com>
Mon, 8 Jul 2019 14:09:52 +0000 (15:09 +0100)
committerMarge Bot <ben+marge-bot@smart-cactus.org>
Wed, 10 Jul 2019 03:01:24 +0000 (23:01 -0400)
commitd2e290d3280841647354ddf5ca9abdd974bce0d5
treef8e2274f28a725ed0a7d32753e3aefc64d2a69a2
parenta35e091616a24b57c229cf50c8d43f8f6bfb5524
Fix erroneous float in CoreOpt

The simple optimiser was making an invalid transformation
to join points -- yikes.  The fix is easy.

I also added some documentation about the fact that GHC uses
a slightly more restrictive version of join points than does
the paper.

Fix #16918
compiler/coreSyn/CoreLint.hs
compiler/coreSyn/CoreOpt.hs
compiler/coreSyn/CoreSyn.hs
testsuite/tests/simplCore/should_compile/T16918.hs [new file with mode: 0644]
testsuite/tests/simplCore/should_compile/T16918a.hs [new file with mode: 0644]
testsuite/tests/simplCore/should_compile/all.T