summaryrefslogtreecommitdiff
path: root/testsuite/tests/safeHaskell/safeInfered
diff options
context:
space:
mode:
authorJoachim Breitner <mail@joachim-breitner.de>2021-03-10 15:28:48 -0500
committerBen Gamari <ben@smart-cactus.org>2021-03-10 16:58:50 -0500
commit115cd3c85a8c38f1fe2a10d4ee515f92c96dd5a2 (patch)
tree19214707fa15f127d05ae515c74cff7e85776a7c /testsuite/tests/safeHaskell/safeInfered
parent30ccf9ed1f592531dac9f3d750278fac6303c3e4 (diff)
downloadhaskell-115cd3c85a8c38f1fe2a10d4ee515f92c96dd5a2.tar.gz
Use GHC2021 as default language
Diffstat (limited to 'testsuite/tests/safeHaskell/safeInfered')
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/Mixed02.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/Mixed02.stderr2
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/Mixed03.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/Mixed03.stderr2
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/SafeInfered01.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/SafeInfered01_A.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/SafeInfered02.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/SafeInfered02_A.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/SafeInfered03.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/SafeInfered03_A.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/SafeInfered04.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/SafeInfered04_A.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/SafeInfered05.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/SafeInfered05.stderr4
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/SafeInfered05_A.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/SafeWarn01.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/SafeWarn01.stderr2
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/T16689.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/TrustworthySafe02.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/TrustworthySafe02.stderr2
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/TrustworthySafe03.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/TrustworthySafe03.stderr2
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeInfered01.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeInfered01.stderr2
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeInfered02.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeInfered02.stderr2
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeInfered03.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeInfered03.stderr2
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeInfered05.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeInfered05.stderr2
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeInfered06.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeInfered06.stderr2
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeInfered08.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeInfered08_A.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeInfered09.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeInfered09.stderr2
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeInfered10.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeInfered10.stderr2
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeInfered11.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeInfered11.stderr6
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeInfered11_A.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeInfered12.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeInfered12.stderr4
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeInfered13.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeInfered14.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeInfered15.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeInfered16.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeInfered17.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeInfered18.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeInfered18.stderr2
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeInfered19.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeWarn01.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeWarn01.stderr4
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeWarn02.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeWarn02.stderr4
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeWarn03.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeWarn03.stderr4
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeWarn04.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeWarn04.stderr4
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeWarn05.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeWarn05.stderr8
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeWarn06.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeWarn06.stderr4
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeWarn07.hs1
-rw-r--r--testsuite/tests/safeHaskell/safeInfered/UnsafeWarn07.stderr4
65 files changed, 78 insertions, 36 deletions
diff --git a/testsuite/tests/safeHaskell/safeInfered/Mixed02.hs b/testsuite/tests/safeHaskell/safeInfered/Mixed02.hs
index 062c2db64d..165feca79b 100644
--- a/testsuite/tests/safeHaskell/safeInfered/Mixed02.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/Mixed02.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# LANGUAGE Unsafe #-}
-- | Should fail compilation because we import Data.Word as safe and unsafe
module Mixed02 where
diff --git a/testsuite/tests/safeHaskell/safeInfered/Mixed02.stderr b/testsuite/tests/safeHaskell/safeInfered/Mixed02.stderr
index b170a4550d..9fa48d4338 100644
--- a/testsuite/tests/safeHaskell/safeInfered/Mixed02.stderr
+++ b/testsuite/tests/safeHaskell/safeInfered/Mixed02.stderr
@@ -1,3 +1,3 @@
-Mixed02.hs:5:1:
+Mixed02.hs:6:1: error:
Module DW is imported both as a safe and unsafe import!
diff --git a/testsuite/tests/safeHaskell/safeInfered/Mixed03.hs b/testsuite/tests/safeHaskell/safeInfered/Mixed03.hs
index fba39654d9..9212656d6c 100644
--- a/testsuite/tests/safeHaskell/safeInfered/Mixed03.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/Mixed03.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# LANGUAGE Unsafe #-}
-- | Should fail compilation because we import Data.Word as safe and unsafe
module Mixed03 where
diff --git a/testsuite/tests/safeHaskell/safeInfered/Mixed03.stderr b/testsuite/tests/safeHaskell/safeInfered/Mixed03.stderr
index 4f4dcccbcf..0a9523ca33 100644
--- a/testsuite/tests/safeHaskell/safeInfered/Mixed03.stderr
+++ b/testsuite/tests/safeHaskell/safeInfered/Mixed03.stderr
@@ -1,3 +1,3 @@
-Mixed03.hs:5:1:
+Mixed03.hs:6:1: error:
Module DW is imported both as a safe and unsafe import!
diff --git a/testsuite/tests/safeHaskell/safeInfered/SafeInfered01.hs b/testsuite/tests/safeHaskell/safeInfered/SafeInfered01.hs
index 0e48580c98..a1e953ced5 100644
--- a/testsuite/tests/safeHaskell/safeInfered/SafeInfered01.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/SafeInfered01.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# LANGUAGE Safe #-}
module SafeInfered01 where
diff --git a/testsuite/tests/safeHaskell/safeInfered/SafeInfered01_A.hs b/testsuite/tests/safeHaskell/safeInfered/SafeInfered01_A.hs
index f66ac43d78..9f52c43f40 100644
--- a/testsuite/tests/safeHaskell/safeInfered/SafeInfered01_A.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/SafeInfered01_A.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
-- | Trivial Safe Module
module SafeInfered01_A where
diff --git a/testsuite/tests/safeHaskell/safeInfered/SafeInfered02.hs b/testsuite/tests/safeHaskell/safeInfered/SafeInfered02.hs
index 6656c5acf7..c1e4c37c99 100644
--- a/testsuite/tests/safeHaskell/safeInfered/SafeInfered02.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/SafeInfered02.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# LANGUAGE Safe #-}
module SafeInfered02 where
diff --git a/testsuite/tests/safeHaskell/safeInfered/SafeInfered02_A.hs b/testsuite/tests/safeHaskell/safeInfered/SafeInfered02_A.hs
index 57438d2761..bf9b8c9e70 100644
--- a/testsuite/tests/safeHaskell/safeInfered/SafeInfered02_A.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/SafeInfered02_A.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# LANGUAGE DeriveDataTypeable #-}
-- | Only uses deriving of Typeable so should be considered safe
module SafeInfered02_A where
diff --git a/testsuite/tests/safeHaskell/safeInfered/SafeInfered03.hs b/testsuite/tests/safeHaskell/safeInfered/SafeInfered03.hs
index 9c7af12231..cea614c558 100644
--- a/testsuite/tests/safeHaskell/safeInfered/SafeInfered03.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/SafeInfered03.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# LANGUAGE Safe #-}
module SafeInfered03 where
diff --git a/testsuite/tests/safeHaskell/safeInfered/SafeInfered03_A.hs b/testsuite/tests/safeHaskell/safeInfered/SafeInfered03_A.hs
index 9844ec6525..d6947e2d27 100644
--- a/testsuite/tests/safeHaskell/safeInfered/SafeInfered03_A.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/SafeInfered03_A.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# LANGUAGE ForeignFunctionInterface #-}
-- | FFI but in IO monad so safe
module SafeInfered03_A where
diff --git a/testsuite/tests/safeHaskell/safeInfered/SafeInfered04.hs b/testsuite/tests/safeHaskell/safeInfered/SafeInfered04.hs
index 8752383a6b..deb2e8494f 100644
--- a/testsuite/tests/safeHaskell/safeInfered/SafeInfered04.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/SafeInfered04.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# LANGUAGE Safe #-}
module SafeInfered04 where
diff --git a/testsuite/tests/safeHaskell/safeInfered/SafeInfered04_A.hs b/testsuite/tests/safeHaskell/safeInfered/SafeInfered04_A.hs
index 6f4db5db79..da7e808acb 100644
--- a/testsuite/tests/safeHaskell/safeInfered/SafeInfered04_A.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/SafeInfered04_A.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# OPTIONS_GHC -fenable-rewrite-rules #-}
-- | Safe as while it enables rules it doesn't define any. UnsafeInfered05 is a
-- test case for when rules are defined and it should be unsafe
diff --git a/testsuite/tests/safeHaskell/safeInfered/SafeInfered05.hs b/testsuite/tests/safeHaskell/safeInfered/SafeInfered05.hs
index 1e933ac3b0..ad4f232cc2 100644
--- a/testsuite/tests/safeHaskell/safeInfered/SafeInfered05.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/SafeInfered05.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# LANGUAGE Unsafe #-}
{-# LANGUAGE OverlappingInstances #-}
{-# LANGUAGE FlexibleInstances #-}
diff --git a/testsuite/tests/safeHaskell/safeInfered/SafeInfered05.stderr b/testsuite/tests/safeHaskell/safeInfered/SafeInfered05.stderr
index 5d194064b8..7815bb7c81 100644
--- a/testsuite/tests/safeHaskell/safeInfered/SafeInfered05.stderr
+++ b/testsuite/tests/safeHaskell/safeInfered/SafeInfered05.stderr
@@ -1,8 +1,8 @@
-SafeInfered05.hs:2:14: warning:
+SafeInfered05.hs:3:14: warning:
-XOverlappingInstances is deprecated: instead use per-instance pragmas OVERLAPPING/OVERLAPPABLE/OVERLAPS
[1 of 2] Compiling SafeInfered05_A ( SafeInfered05_A.hs, SafeInfered05_A.o )
-SafeInfered05_A.hs:2:16: warning: [-Wsafe]
+SafeInfered05_A.hs:3:16: warning: [-Wsafe]
‘SafeInfered05_A’ has been inferred as safe!
[2 of 2] Compiling SafeInfered05 ( SafeInfered05.hs, SafeInfered05.o )
diff --git a/testsuite/tests/safeHaskell/safeInfered/SafeInfered05_A.hs b/testsuite/tests/safeHaskell/safeInfered/SafeInfered05_A.hs
index c9e5c964cb..72eeaeb097 100644
--- a/testsuite/tests/safeHaskell/safeInfered/SafeInfered05_A.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/SafeInfered05_A.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# LANGUAGE FlexibleInstances #-}
{-# OPTIONS_GHC -fwarn-safe #-}
module SafeInfered05_A where
diff --git a/testsuite/tests/safeHaskell/safeInfered/SafeWarn01.hs b/testsuite/tests/safeHaskell/safeInfered/SafeWarn01.hs
index 507367929b..84ed104d43 100644
--- a/testsuite/tests/safeHaskell/safeInfered/SafeWarn01.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/SafeWarn01.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# LANGUAGE Unsafe #-}
{-# OPTIONS_GHC -fwarn-safe #-}
{-# OPTIONS_GHC -fwarn-unsafe #-}
diff --git a/testsuite/tests/safeHaskell/safeInfered/SafeWarn01.stderr b/testsuite/tests/safeHaskell/safeInfered/SafeWarn01.stderr
index 5e824de641..7efaba3490 100644
--- a/testsuite/tests/safeHaskell/safeInfered/SafeWarn01.stderr
+++ b/testsuite/tests/safeHaskell/safeInfered/SafeWarn01.stderr
@@ -1,3 +1,3 @@
-SafeWarn01.hs:2:16: warning: [-Wsafe]
+SafeWarn01.hs:3:16: warning: [-Wsafe]
‘SafeWarn01’ has been inferred as safe!
diff --git a/testsuite/tests/safeHaskell/safeInfered/T16689.hs b/testsuite/tests/safeHaskell/safeInfered/T16689.hs
index a1820aa4a1..2621ec6cff 100644
--- a/testsuite/tests/safeHaskell/safeInfered/T16689.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/T16689.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# LANGUAGE Safe #-}
main = return ()
diff --git a/testsuite/tests/safeHaskell/safeInfered/TrustworthySafe02.hs b/testsuite/tests/safeHaskell/safeInfered/TrustworthySafe02.hs
index 9dfaccd950..5a374cb99d 100644
--- a/testsuite/tests/safeHaskell/safeInfered/TrustworthySafe02.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/TrustworthySafe02.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# LANGUAGE Trustworthy #-}
{-# OPTIONS_GHC -fwarn-trustworthy-safe #-}
diff --git a/testsuite/tests/safeHaskell/safeInfered/TrustworthySafe02.stderr b/testsuite/tests/safeHaskell/safeInfered/TrustworthySafe02.stderr
index 7d42cb016f..7723e98dc1 100644
--- a/testsuite/tests/safeHaskell/safeInfered/TrustworthySafe02.stderr
+++ b/testsuite/tests/safeHaskell/safeInfered/TrustworthySafe02.stderr
@@ -1,3 +1,3 @@
-TrustworthySafe02.hs:1:14: warning: [-Wtrustworthy-safe (in -Wall)]
+TrustworthySafe02.hs:2:14: warning: [-Wtrustworthy-safe (in -Wall)]
‘TrustworthySafe02’ is marked as Trustworthy but has been inferred as safe!
diff --git a/testsuite/tests/safeHaskell/safeInfered/TrustworthySafe03.hs b/testsuite/tests/safeHaskell/safeInfered/TrustworthySafe03.hs
index ad63e090e1..fe3e27ef5f 100644
--- a/testsuite/tests/safeHaskell/safeInfered/TrustworthySafe03.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/TrustworthySafe03.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# LANGUAGE Trustworthy #-}
{-# OPTIONS_GHC -Wall #-}
{-# OPTIONS_GHC -fwarn-trustworthy-safe #-} -- temp broken by 452d6aa95
diff --git a/testsuite/tests/safeHaskell/safeInfered/TrustworthySafe03.stderr b/testsuite/tests/safeHaskell/safeInfered/TrustworthySafe03.stderr
index 9938109dcb..ff4a4e3631 100644
--- a/testsuite/tests/safeHaskell/safeInfered/TrustworthySafe03.stderr
+++ b/testsuite/tests/safeHaskell/safeInfered/TrustworthySafe03.stderr
@@ -1,3 +1,3 @@
-TrustworthySafe03.hs:1:14: warning: [-Wtrustworthy-safe (in -Wall)]
+TrustworthySafe03.hs:2:14: warning: [-Wtrustworthy-safe (in -Wall)]
‘TrustworthySafe03’ is marked as Trustworthy but has been inferred as safe!
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered01.hs b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered01.hs
index b1db9ea578..0a356f190b 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered01.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered01.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# LANGUAGE Safe #-}
module UnsafeInfered01 where
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered01.stderr b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered01.stderr
index 4e705d6a16..2698172348 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered01.stderr
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered01.stderr
@@ -1,6 +1,6 @@
[1 of 2] Compiling UnsafeInfered01_A ( UnsafeInfered01_A.hs, UnsafeInfered01_A.o )
[2 of 2] Compiling UnsafeInfered01 ( UnsafeInfered01.hs, UnsafeInfered01.o )
-UnsafeInfered01.hs:4:1: error:
+UnsafeInfered01.hs:5:1: error:
UnsafeInfered01_A: Can't be safely imported!
The module itself isn't safe.
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered02.hs b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered02.hs
index 67105965d8..f41e7e32f3 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered02.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered02.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# LANGUAGE Safe #-}
module UnsafeInfered02 where
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered02.stderr b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered02.stderr
index e5593d57e9..203e241c99 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered02.stderr
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered02.stderr
@@ -1,6 +1,6 @@
[1 of 2] Compiling UnsafeInfered02_A ( UnsafeInfered02_A.hs, UnsafeInfered02_A.o, UnsafeInfered02_A.dyn_o )
[2 of 2] Compiling UnsafeInfered02 ( UnsafeInfered02.hs, UnsafeInfered02.o, UnsafeInfered02.dyn_o )
-UnsafeInfered02.hs:4:1: error:
+UnsafeInfered02.hs:5:1: error:
UnsafeInfered02_A: Can't be safely imported!
The module itself isn't safe.
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered03.hs b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered03.hs
index 67220ac4d0..115070b573 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered03.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered03.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# LANGUAGE Safe #-}
module UnsafeInfered03 where
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered03.stderr b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered03.stderr
index 8a48fec4b0..b722af9bc9 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered03.stderr
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered03.stderr
@@ -1,6 +1,6 @@
[1 of 2] Compiling UnsafeInfered03_A ( UnsafeInfered03_A.hs, UnsafeInfered03_A.o )
[2 of 2] Compiling UnsafeInfered03 ( UnsafeInfered03.hs, UnsafeInfered03.o )
-UnsafeInfered03.hs:4:1: error:
+UnsafeInfered03.hs:5:1: error:
UnsafeInfered03_A: Can't be safely imported!
The module itself isn't safe.
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered05.hs b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered05.hs
index 712d02a350..4bf2b2bddc 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered05.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered05.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# LANGUAGE Safe #-}
module UnsafeInfered05 where
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered05.stderr b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered05.stderr
index e70f03df38..4a0eb8000d 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered05.stderr
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered05.stderr
@@ -1,6 +1,6 @@
[1 of 2] Compiling UnsafeInfered05_A ( UnsafeInfered05_A.hs, UnsafeInfered05_A.o )
[2 of 2] Compiling UnsafeInfered05 ( UnsafeInfered05.hs, UnsafeInfered05.o )
-UnsafeInfered05.hs:4:1: error:
+UnsafeInfered05.hs:5:1: error:
UnsafeInfered05_A: Can't be safely imported!
The module itself isn't safe.
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered06.hs b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered06.hs
index a5bb127202..f12f5f90df 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered06.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered06.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# LANGUAGE Safe #-}
module UnsafeInfered06 where
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered06.stderr b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered06.stderr
index 42c8c3d1e5..623f4aea3c 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered06.stderr
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered06.stderr
@@ -1,6 +1,6 @@
[1 of 2] Compiling UnsafeInfered06_A ( UnsafeInfered06_A.hs, UnsafeInfered06_A.o )
[2 of 2] Compiling UnsafeInfered06 ( UnsafeInfered06.hs, UnsafeInfered06.o )
-UnsafeInfered06.hs:4:1: error:
+UnsafeInfered06.hs:5:1: error:
UnsafeInfered06_A: Can't be safely imported!
The module itself isn't safe.
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered08.hs b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered08.hs
index 394d7e6999..b9e2eff6ca 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered08.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered08.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# LANGUAGE Safe #-}
module UnsafeInfered08 where
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered08_A.hs b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered08_A.hs
index d88eda96b1..d8c5137c82 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered08_A.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered08_A.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# LANGUAGE OverlappingInstances #-}
{-# OPTIONS_GHC -w #-} -- Turn off deprecation for OverlappingInstances
-- | Safe, as we now check at overlap occurrence, not definition.
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered09.hs b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered09.hs
index 1c1e61d3c5..4dcd5c82ea 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered09.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered09.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# LANGUAGE Safe #-}
module UnsafeInfered09 where
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered09.stderr b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered09.stderr
index bf9b623eaa..b5ddab3f35 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered09.stderr
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered09.stderr
@@ -2,6 +2,6 @@
[2 of 3] Compiling UnsafeInfered09_A ( UnsafeInfered09_A.hs, UnsafeInfered09_A.o )
[3 of 3] Compiling UnsafeInfered09 ( UnsafeInfered09.hs, UnsafeInfered09.o )
-UnsafeInfered09.hs:4:1: error:
+UnsafeInfered09.hs:5:1: error:
UnsafeInfered09_A: Can't be safely imported!
The module itself isn't safe.
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered10.hs b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered10.hs
index 3ba1584b08..ddedb09407 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered10.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered10.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# LANGUAGE Safe #-}
-- | Basic test to see if no safe infer flag works
module UnsafeInfered10 where
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered10.stderr b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered10.stderr
index f626cf952f..fb4488000b 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered10.stderr
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered10.stderr
@@ -1,6 +1,6 @@
[1 of 2] Compiling UnsafeInfered10_A ( UnsafeInfered10_A.hs, UnsafeInfered10_A.o )
[2 of 2] Compiling UnsafeInfered10 ( UnsafeInfered10.hs, UnsafeInfered10.o )
-UnsafeInfered10.hs:5:1: error:
+UnsafeInfered10.hs:6:1: error:
UnsafeInfered10_A: Can't be safely imported!
The module itself isn't safe.
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered11.hs b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered11.hs
index 34555594e9..c8fd8b3f7b 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered11.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered11.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# LANGUAGE Safe #-}
-- | Basic test to see if no safe infer flag works
module UnsafeInfered11 where
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered11.stderr b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered11.stderr
index 18a6a459c7..919eec4e6b 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered11.stderr
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered11.stderr
@@ -1,13 +1,13 @@
[1 of 2] Compiling UnsafeInfered11_A ( UnsafeInfered11_A.hs, UnsafeInfered11_A.o )
-UnsafeInfered11_A.hs:1:16: warning: [-Wunsafe]
+UnsafeInfered11_A.hs:2:16: warning: [-Wunsafe]
‘UnsafeInfered11_A’ has been inferred as unsafe!
Reason:
- UnsafeInfered11_A.hs:17:11: warning:
+ UnsafeInfered11_A.hs:18:11: warning:
Rule "lookupx/T" ignored
User defined rules are disabled under Safe Haskell
[2 of 2] Compiling UnsafeInfered11 ( UnsafeInfered11.hs, UnsafeInfered11.o )
-UnsafeInfered11.hs:5:1: error:
+UnsafeInfered11.hs:6:1: error:
UnsafeInfered11_A: Can't be safely imported!
The module itself isn't safe.
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered11_A.hs b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered11_A.hs
index d209dcf5fe..aefaacac30 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered11_A.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered11_A.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# OPTIONS_GHC -fwarn-unsafe #-}
{-# OPTIONS_GHC -fenable-rewrite-rules #-}
-- | Basic test to see if no safe infer flag works
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered12.hs b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered12.hs
index a39b46e2a0..24ae448a88 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered12.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered12.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# LANGUAGE TemplateHaskell #-}
{-# OPTIONS_GHC -fwarn-unsafe -Werror #-}
module UnsafeInfered12 where
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered12.stderr b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered12.stderr
index f05bf7fa8c..e3529474bd 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered12.stderr
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered12.stderr
@@ -1,6 +1,6 @@
-UnsafeInfered12.hs:2:16: error: [-Wunsafe, -Werror=unsafe]
+UnsafeInfered12.hs:3:16: error: [-Wunsafe, -Werror=unsafe]
‘UnsafeInfered12’ has been inferred as unsafe!
Reason:
- UnsafeInfered12.hs:1:14:
+ UnsafeInfered12.hs:2:14:
-XTemplateHaskell is not allowed in Safe Haskell
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered13.hs b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered13.hs
index defc3a5243..ae9281643e 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered13.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered13.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# OPTIONS_GHC -fwarn-unsafe -Werror #-}
{-# LANGUAGE FlexibleInstances #-}
module UnsafeInfered13 where
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered14.hs b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered14.hs
index 5b9f64210f..644c63f4cf 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered14.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered14.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# OPTIONS_GHC -fwarn-unsafe -Werror #-}
{-# LANGUAGE FlexibleInstances #-}
module UnsafeInfered14 where
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered15.hs b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered15.hs
index 427c97b0ac..72008319c5 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered15.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered15.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# OPTIONS_GHC -fwarn-unsafe -Werror #-}
{-# LANGUAGE FlexibleInstances #-}
module UnsafeInfered15 where
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered16.hs b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered16.hs
index b3e7f34586..ffc65d093b 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered16.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered16.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# OPTIONS_GHC -fwarn-unsafe -Werror #-}
{-# LANGUAGE FlexibleInstances #-}
module UnsafeInfered16 where
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered17.hs b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered17.hs
index 7f17a136ff..ff2abe647d 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered17.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered17.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# OPTIONS_GHC -fwarn-unsafe -Werror #-}
{-# LANGUAGE FlexibleInstances #-}
module UnsafeInfered17 where
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered18.hs b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered18.hs
index a6dbfe1745..1aaaf8e47a 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered18.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered18.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# OPTIONS_GHC -fwarn-unsafe #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE OverlappingInstances #-}
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered18.stderr b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered18.stderr
index 58db37d3f0..2e15aa3954 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered18.stderr
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered18.stderr
@@ -1,3 +1,3 @@
-UnsafeInfered18.hs:3:14: warning:
+UnsafeInfered18.hs:4:14: warning:
-XOverlappingInstances is deprecated: instead use per-instance pragmas OVERLAPPING/OVERLAPPABLE/OVERLAPS
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered19.hs b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered19.hs
index 587bc4edbf..4b0b33b410 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered19.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeInfered19.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# OPTIONS_GHC -fwarn-unsafe -Werror #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE IncoherentInstances #-}
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn01.hs b/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn01.hs
index afe188db4f..f3eeea02ad 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn01.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn01.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# OPTIONS_GHC -fwarn-safe #-}
{-# OPTIONS_GHC -fwarn-unsafe #-}
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn01.stderr b/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn01.stderr
index 6d2afb2193..5424c5f2a2 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn01.stderr
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn01.stderr
@@ -1,7 +1,7 @@
-UnsafeWarn01.hs:2:16: warning: [-Wunsafe]
+UnsafeWarn01.hs:3:16: warning: [-Wunsafe]
‘UnsafeWarn01’ has been inferred as unsafe!
Reason:
- UnsafeWarn01.hs:7:1: error:
+ UnsafeWarn01.hs:8:1: error:
System.IO.Unsafe: Can't be safely imported!
The module itself isn't safe.
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn02.hs b/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn02.hs
index 6f62ca5c94..0d1924bf8f 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn02.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn02.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# OPTIONS_GHC -fwarn-safe #-}
{-# OPTIONS_GHC -fwarn-unsafe #-}
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn02.stderr b/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn02.stderr
index 2ee83ac140..881db587d5 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn02.stderr
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn02.stderr
@@ -1,6 +1,6 @@
-UnsafeWarn02.hs:2:16: warning: [-Wunsafe]
+UnsafeWarn02.hs:3:16: warning: [-Wunsafe]
‘UnsafeWarn02’ has been inferred as unsafe!
Reason:
- UnsafeWarn02.hs:4:14:
+ UnsafeWarn02.hs:5:14:
-XTemplateHaskell is not allowed in Safe Haskell
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn03.hs b/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn03.hs
index ded02de888..433824f8bd 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn03.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn03.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# LANGUAGE Trustworthy #-}
{-# OPTIONS_GHC -fwarn-safe #-}
{-# OPTIONS_GHC -fwarn-unsafe #-}
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn03.stderr b/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn03.stderr
index 6ddea45af1..ba23b72ee1 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn03.stderr
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn03.stderr
@@ -1,7 +1,7 @@
-UnsafeWarn03.hs:3:16: warning: [-Wunsafe]
+UnsafeWarn03.hs:4:16: warning: [-Wunsafe]
‘UnsafeWarn03’ has been inferred as unsafe!
Reason:
- UnsafeWarn03.hs:8:1: error:
+ UnsafeWarn03.hs:9:1: error:
System.IO.Unsafe: Can't be safely imported!
The module itself isn't safe.
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn04.hs b/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn04.hs
index d8e8b84fa5..1d02985734 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn04.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn04.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# LANGUAGE Trustworthy #-}
{-# OPTIONS_GHC -fwarn-trustworthy-safe #-}
{-# OPTIONS_GHC -fwarn-unsafe #-}
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn04.stderr b/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn04.stderr
index c91f421344..90e6d5b6f1 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn04.stderr
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn04.stderr
@@ -1,7 +1,7 @@
-UnsafeWarn04.hs:3:16: warning: [-Wunsafe]
+UnsafeWarn04.hs:4:16: warning: [-Wunsafe]
‘UnsafeWarn04’ has been inferred as unsafe!
Reason:
- UnsafeWarn04.hs:8:1: error:
+ UnsafeWarn04.hs:9:1: error:
System.IO.Unsafe: Can't be safely imported!
The module itself isn't safe.
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn05.hs b/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn05.hs
index 76258d362b..3c9b3109f7 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn05.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn05.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# LANGUAGE Unsafe #-}
{-# OPTIONS_GHC -fwarn-trustworthy-safe #-}
{-# OPTIONS_GHC -fwarn-safe #-}
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn05.stderr b/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn05.stderr
index dfd4193b7a..2977504457 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn05.stderr
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn05.stderr
@@ -1,14 +1,14 @@
-UnsafeWarn05.hs:4:16: warning: [-Wunsafe]
+UnsafeWarn05.hs:5:16: warning: [-Wunsafe]
‘UnsafeWarn05’ has been inferred as unsafe!
Reason:
- UnsafeWarn05.hs:10:1: error:
+ UnsafeWarn05.hs:11:1: error:
System.IO.Unsafe: Can't be safely imported!
The module itself isn't safe.
-UnsafeWarn05.hs:4:16: warning: [-Wunsafe]
+UnsafeWarn05.hs:5:16: warning: [-Wunsafe]
‘UnsafeWarn05’ has been inferred as unsafe!
Reason:
- UnsafeWarn05.hs:15:11: warning:
+ UnsafeWarn05.hs:16:11: warning:
Rule "g" ignored
User defined rules are disabled under Safe Haskell
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn06.hs b/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn06.hs
index 671a64822b..8680fe5d6f 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn06.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn06.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# OPTIONS_GHC -fenable-rewrite-rules #-}
{-# OPTIONS_GHC -fwarn-safe #-}
{-# OPTIONS_GHC -fwarn-unsafe #-}
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn06.stderr b/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn06.stderr
index 323bb19a39..98b1360202 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn06.stderr
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn06.stderr
@@ -1,7 +1,7 @@
-UnsafeWarn06.hs:3:16: warning: [-Wunsafe]
+UnsafeWarn06.hs:4:16: warning: [-Wunsafe]
‘UnsafeWarn06’ has been inferred as unsafe!
Reason:
- UnsafeWarn06.hs:8:11: warning:
+ UnsafeWarn06.hs:9:11: warning:
Rule "f" ignored
User defined rules are disabled under Safe Haskell
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn07.hs b/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn07.hs
index 43982939b8..7efc9157e7 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn07.hs
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn07.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE Haskell2010 #-}
{-# LANGUAGE Trustworthy #-}
{-# OPTIONS_GHC -fenable-rewrite-rules #-}
{-# OPTIONS_GHC -fwarn-safe #-}
diff --git a/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn07.stderr b/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn07.stderr
index 11116b6460..91a4ec3547 100644
--- a/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn07.stderr
+++ b/testsuite/tests/safeHaskell/safeInfered/UnsafeWarn07.stderr
@@ -1,7 +1,7 @@
-UnsafeWarn07.hs:4:16: warning: [-Wunsafe]
+UnsafeWarn07.hs:5:16: warning: [-Wunsafe]
‘UnsafeWarn07’ has been inferred as unsafe!
Reason:
- UnsafeWarn07.hs:9:11: warning:
+ UnsafeWarn07.hs:10:11: warning:
Rule "f" ignored
User defined rules are disabled under Safe Haskell