summaryrefslogtreecommitdiff
path: root/compiler/simplCore/SimplCore.lhs
diff options
context:
space:
mode:
authorSimon Peyton Jones <simonpj@microsoft.com>2011-11-27 19:44:19 +0000
committerSimon Peyton Jones <simonpj@microsoft.com>2011-11-27 19:44:19 +0000
commite704a95889681bd58e0a7cebfcc0e98193e46343 (patch)
tree4455e7078037f389882b546a2e0791c3d45df49f /compiler/simplCore/SimplCore.lhs
parent878206f9bd64e5e6f35851dab2c413e6fdab0012 (diff)
downloadhaskell-e704a95889681bd58e0a7cebfcc0e98193e46343.tar.gz
Don't indirection-zap a function that has a stable unfolding
This was responsible for Trac #5001, and it was a real bug; an inlining could be lost.
Diffstat (limited to 'compiler/simplCore/SimplCore.lhs')
-rw-r--r--compiler/simplCore/SimplCore.lhs1
1 files changed, 1 insertions, 0 deletions
diff --git a/compiler/simplCore/SimplCore.lhs b/compiler/simplCore/SimplCore.lhs
index 1081ce0752..03ffb479db 100644
--- a/compiler/simplCore/SimplCore.lhs
+++ b/compiler/simplCore/SimplCore.lhs
@@ -885,6 +885,7 @@ hasShortableIdInfo :: Id -> Bool
hasShortableIdInfo id
= isEmptySpecInfo (specInfo info)
&& isDefaultInlinePragma (inlinePragInfo info)
+ && not (isStableUnfolding (unfoldingInfo info))
where
info = idInfo id