[commit: ghc] wip/T13861: don't inline 'same', this way one of the mysteries is resolved (f949c69)

git at git.haskell.org git at git.haskell.org
Fri Dec 22 21:16:38 UTC 2017


Repository : ssh://git@git.haskell.org/ghc

On branch  : wip/T13861
Link       : http://ghc.haskell.org/trac/ghc/changeset/f949c690c456cc51078e39619554be645384b83c/ghc

>---------------------------------------------------------------

commit f949c690c456cc51078e39619554be645384b83c
Author: Gabor Greif <ggreif at gmail.com>
Date:   Fri Dec 22 22:16:11 2017 +0100

    don't inline 'same', this way one of the mysteries is resolved


>---------------------------------------------------------------

f949c690c456cc51078e39619554be645384b83c
 testsuite/tests/simplStg/should_run/T13861.hs     | 1 +
 testsuite/tests/simplStg/should_run/T13861.stdout | 2 +-
 2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/testsuite/tests/simplStg/should_run/T13861.hs b/testsuite/tests/simplStg/should_run/T13861.hs
index 2cb12cc..4130a51 100644
--- a/testsuite/tests/simplStg/should_run/T13861.hs
+++ b/testsuite/tests/simplStg/should_run/T13861.hs
@@ -93,3 +93,4 @@ same :: a -> b -> IO ()
 same x y = case reallyUnsafePtrEquality# (unsafeCoerce x) y of
     1# -> putStrLn "yes"
     _  -> putStrLn "no"
+{-# NOINLINE same #-}
diff --git a/testsuite/tests/simplStg/should_run/T13861.stdout b/testsuite/tests/simplStg/should_run/T13861.stdout
index 50228bd..40aa293 100644
--- a/testsuite/tests/simplStg/should_run/T13861.stdout
+++ b/testsuite/tests/simplStg/should_run/T13861.stdout
@@ -2,7 +2,7 @@ yes
 yes
 no
 no
-no
+yes
 no
 no
 yes



More information about the ghc-commits mailing list