[Git][ghc/ghc][wip/T23355] Add a test for #23355

Krzysztof Gogolewski (@monoidal) gitlab at gitlab.haskell.org
Wed May 24 15:49:45 UTC 2023



Krzysztof Gogolewski pushed to branch wip/T23355 at Glasgow Haskell Compiler / GHC


Commits:
7a51d5f9 by Krzysztof Gogolewski at 2023-05-24T17:49:33+02:00
Add a test for #23355

It was fixed by !10061, so I'm adding it in the same group.

- - - - -


3 changed files:

- + testsuite/tests/ghci/should_run/T22958c.hs
- + testsuite/tests/ghci/should_run/T22958c.stdout
- testsuite/tests/ghci/should_run/all.T


Changes:

=====================================
testsuite/tests/ghci/should_run/T22958c.hs
=====================================
@@ -0,0 +1,15 @@
+-- Test extracted from text-builder-linear, ticket #23355
+{-# LANGUAGE UnliftedDatatypes #-}
+module Main (main) where
+
+import GHC.Exts (UnliftedType)
+
+type Buffer :: UnliftedType
+data Buffer = Buffer
+
+main :: IO ()
+main = case i Buffer of Buffer -> putStrLn "good"
+
+{-# NOINLINE i #-}
+i :: forall (a :: UnliftedType). a -> a
+i x = x


=====================================
testsuite/tests/ghci/should_run/T22958c.stdout
=====================================
@@ -0,0 +1 @@
+good


=====================================
testsuite/tests/ghci/should_run/all.T
=====================================
@@ -90,3 +90,4 @@ test('T22829', just_ghci + [extra_hc_opts("-Wmissing-import-lists -Werror")], co
 test('T23229', just_ghci + [extra_hc_opts("-this-unit-id my-package -Wno-missing-methods T23229")], ghci_script, ['T23229.script'])
 test('T22958a', just_ghci, compile_and_run, [''])
 test('T22958b', just_ghci, compile_and_run, [''])
+test('T22958c', just_ghci, compile_and_run, [''])



View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/7a51d5f918c922ec3b684ce6adfc976664288a82

-- 
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/7a51d5f918c922ec3b684ce6adfc976664288a82
You're receiving this email because of your account on gitlab.haskell.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/ghc-commits/attachments/20230524/bd148ced/attachment-0001.html>


More information about the ghc-commits mailing list