summaryrefslogtreecommitdiff
path: root/testsuite/tests/stranal
diff options
context:
space:
mode:
authorSebastian Graf <sebastian.graf@kit.edu>2022-06-27 18:25:17 +0200
committerSebastian Graf <sebastian.graf@kit.edu>2022-09-30 18:42:13 +0200
commitf5e8f493b015df859833beac5a8e64a0f9b9d4f4 (patch)
treea43125076a21b6d821b4b9235838fb1c63268cd1 /testsuite/tests/stranal
parentea0083bf56b222579b586c8247031e04c80c15f1 (diff)
downloadhaskell-f5e8f493b015df859833beac5a8e64a0f9b9d4f4.tar.gz
Boxity: Don't update Boxity unless worker/wrapper follows (#21754)wip/T21754
A small refactoring in our Core Opt pipeline and some new functions for transfering argument boxities from one signature to another to facilitate `Note [Don't change boxity without worker/wrapper]`. Fixes #21754.
Diffstat (limited to 'testsuite/tests/stranal')
-rw-r--r--testsuite/tests/stranal/sigs/T21754.hs7
-rw-r--r--testsuite/tests/stranal/sigs/T21754.stderr10
-rw-r--r--testsuite/tests/stranal/sigs/all.T1
3 files changed, 18 insertions, 0 deletions
diff --git a/testsuite/tests/stranal/sigs/T21754.hs b/testsuite/tests/stranal/sigs/T21754.hs
new file mode 100644
index 0000000000..37aa9449f8
--- /dev/null
+++ b/testsuite/tests/stranal/sigs/T21754.hs
@@ -0,0 +1,7 @@
+{-# OPTIONS_GHC -fno-worker-wrapper #-}
+
+module Test where
+
+f :: Int -> Int
+f n = n+1
+{-# NOINLINE f #-}
diff --git a/testsuite/tests/stranal/sigs/T21754.stderr b/testsuite/tests/stranal/sigs/T21754.stderr
new file mode 100644
index 0000000000..0370380d8a
--- /dev/null
+++ b/testsuite/tests/stranal/sigs/T21754.stderr
@@ -0,0 +1,10 @@
+
+==================== Strictness signatures ====================
+Test.f: <1L>
+
+
+
+==================== Strictness signatures ====================
+Test.f: <1L>
+
+
diff --git a/testsuite/tests/stranal/sigs/all.T b/testsuite/tests/stranal/sigs/all.T
index 50b8176ce8..73ecf7be57 100644
--- a/testsuite/tests/stranal/sigs/all.T
+++ b/testsuite/tests/stranal/sigs/all.T
@@ -34,5 +34,6 @@ test('T20746b', normal, compile, [''])
test('T21081', normal, compile, [''])
test('T21119', normal, compile, [''])
test('T21717', normal, compile, [''])
+test('T21754', normal, compile, [''])
test('T21888', normal, compile, [''])
test('T21888a', normal, compile, [''])