diff options
Diffstat (limited to 'testsuite/tests/ghci')
-rw-r--r-- | testsuite/tests/ghci/prog009/ghci.prog009.script | 2 | ||||
-rw-r--r-- | testsuite/tests/ghci/prog018/B.hs | 2 | ||||
-rw-r--r-- | testsuite/tests/ghci/prog018/prog018.stdout | 6 | ||||
-rw-r--r-- | testsuite/tests/ghci/scripts/T14828.script | 1 | ||||
-rw-r--r-- | testsuite/tests/ghci/scripts/T8579.script | 2 | ||||
-rw-r--r-- | testsuite/tests/ghci/scripts/T9293.stdout | 4 | ||||
-rw-r--r-- | testsuite/tests/ghci/scripts/T9293.stdout-mingw32 | 4 | ||||
-rw-r--r-- | testsuite/tests/ghci/scripts/ghci004.hs | 2 | ||||
-rw-r--r-- | testsuite/tests/ghci/scripts/ghci024.stdout | 1 | ||||
-rw-r--r-- | testsuite/tests/ghci/scripts/ghci024.stdout-mingw32 | 1 | ||||
-rw-r--r-- | testsuite/tests/ghci/scripts/ghci036.script | 3 | ||||
-rw-r--r-- | testsuite/tests/ghci/scripts/ghci038.hs | 2 | ||||
-rw-r--r-- | testsuite/tests/ghci/scripts/ghci038.script | 6 | ||||
-rw-r--r-- | testsuite/tests/ghci/scripts/ghci038.stdout | 6 | ||||
-rw-r--r-- | testsuite/tests/ghci/scripts/ghci057.stdout | 4 | ||||
-rw-r--r-- | testsuite/tests/ghci/scripts/ghci057.stdout-mingw32 | 4 | ||||
-rw-r--r-- | testsuite/tests/ghci/should_run/ghcirun002.hs | 2 |
17 files changed, 36 insertions, 16 deletions
diff --git a/testsuite/tests/ghci/prog009/ghci.prog009.script b/testsuite/tests/ghci/prog009/ghci.prog009.script index 6005727d44..713735645b 100644 --- a/testsuite/tests/ghci/prog009/ghci.prog009.script +++ b/testsuite/tests/ghci/prog009/ghci.prog009.script @@ -1,5 +1,5 @@ :! cp A1.hs A.hs -import Data.List +import Data.List (nub) :load A -- Data.List should still be in scope: :t nub diff --git a/testsuite/tests/ghci/prog018/B.hs b/testsuite/tests/ghci/prog018/B.hs index ebfdd6d733..fc3a615240 100644 --- a/testsuite/tests/ghci/prog018/B.hs +++ b/testsuite/tests/ghci/prog018/B.hs @@ -4,4 +4,4 @@ module B ) where import A -import Data.List +import Data.Tuple diff --git a/testsuite/tests/ghci/prog018/prog018.stdout b/testsuite/tests/ghci/prog018/prog018.stdout index daa722e436..ba8594dcf5 100644 --- a/testsuite/tests/ghci/prog018/prog018.stdout +++ b/testsuite/tests/ghci/prog018/prog018.stdout @@ -11,9 +11,9 @@ A.hs:8:15: warning: [-Wunused-matches (in -Wextra)] Defined but not used: ‘x’ B.hs:7:1: warning: [-Wunused-imports (in -Wextra)] - The import of ‘Data.List’ is redundant - except perhaps to import instances from ‘Data.List’ - To import instances alone, use: import Data.List() + The import of ‘Data.Tuple’ is redundant + except perhaps to import instances from ‘Data.Tuple’ + To import instances alone, use: import Data.Tuple() C.hs:6:7: error: Variable not in scope: variableNotInScope :: () Failed, two modules loaded. diff --git a/testsuite/tests/ghci/scripts/T14828.script b/testsuite/tests/ghci/scripts/T14828.script index 59d616abde..d8eea69b7c 100644 --- a/testsuite/tests/ghci/scripts/T14828.script +++ b/testsuite/tests/ghci/scripts/T14828.script @@ -14,6 +14,7 @@ :p mempty :p mappend +:set -Wno-compat-unqualified-imports :m + Data.List :p foldl' diff --git a/testsuite/tests/ghci/scripts/T8579.script b/testsuite/tests/ghci/scripts/T8579.script index 64aadf056f..29f1b5b6b3 100644 --- a/testsuite/tests/ghci/scripts/T8579.script +++ b/testsuite/tests/ghci/scripts/T8579.script @@ -1,5 +1,5 @@ data A = X data A = Y :i A -:m Data.List +:m Data.Tuple :i A diff --git a/testsuite/tests/ghci/scripts/T9293.stdout b/testsuite/tests/ghci/scripts/T9293.stdout index 87b950654d..57820fc4ed 100644 --- a/testsuite/tests/ghci/scripts/T9293.stdout +++ b/testsuite/tests/ghci/scripts/T9293.stdout @@ -17,6 +17,7 @@ warning settings: -Wsemigroup -Wnoncanonical-monoid-instances -Wstar-is-type + -Wcompat-unqualified-imports Should fail, GADTs is not enabled options currently set: none. base language is: Haskell2010 @@ -40,6 +41,7 @@ warning settings: -Wsemigroup -Wnoncanonical-monoid-instances -Wstar-is-type + -Wcompat-unqualified-imports Should work, GADTs is in force from :set options currently set: none. base language is: Haskell2010 @@ -62,6 +64,7 @@ warning settings: -Wsemigroup -Wnoncanonical-monoid-instances -Wstar-is-type + -Wcompat-unqualified-imports Should fail, GADTs is now disabled base language is: Haskell2010 with the following modifiers: @@ -86,5 +89,6 @@ warning settings: -Wsemigroup -Wnoncanonical-monoid-instances -Wstar-is-type + -Wcompat-unqualified-imports Should fail, GADTs is only enabled at the prompt C :: T Int diff --git a/testsuite/tests/ghci/scripts/T9293.stdout-mingw32 b/testsuite/tests/ghci/scripts/T9293.stdout-mingw32 index eb3e225419..0873022137 100644 --- a/testsuite/tests/ghci/scripts/T9293.stdout-mingw32 +++ b/testsuite/tests/ghci/scripts/T9293.stdout-mingw32 @@ -16,6 +16,7 @@ warning settings: -Wsemigroup -Wnoncanonical-monoid-instances -Wstar-is-type + -Wcompat-unqualified-imports Should fail, GADTs is not enabled options currently set: none. base language is: Haskell2010 @@ -38,6 +39,7 @@ warning settings: -Wsemigroup -Wnoncanonical-monoid-instances -Wstar-is-type + -Wcompat-unqualified-imports Should work, GADTs is in force from :set options currently set: none. base language is: Haskell2010 @@ -59,6 +61,7 @@ warning settings: -Wsemigroup -Wnoncanonical-monoid-instances -Wstar-is-type + -Wcompat-unqualified-imports Should fail, GADTs is now disabled base language is: Haskell2010 with the following modifiers: @@ -82,5 +85,6 @@ warning settings: -Wsemigroup -Wnoncanonical-monoid-instances -Wstar-is-type + -Wcompat-unqualified-imports Should fail, GADTs is only enabled at the prompt C :: T Int diff --git a/testsuite/tests/ghci/scripts/ghci004.hs b/testsuite/tests/ghci/scripts/ghci004.hs index 6406a11565..d7b34e50f3 100644 --- a/testsuite/tests/ghci/scripts/ghci004.hs +++ b/testsuite/tests/ghci/scripts/ghci004.hs @@ -1,2 +1,2 @@ -import Data.List +import Data.List (sort) main = print (sort [100,99..1]) diff --git a/testsuite/tests/ghci/scripts/ghci024.stdout b/testsuite/tests/ghci/scripts/ghci024.stdout index 138da30075..e4e664ada9 100644 --- a/testsuite/tests/ghci/scripts/ghci024.stdout +++ b/testsuite/tests/ghci/scripts/ghci024.stdout @@ -18,6 +18,7 @@ warning settings: -Wsemigroup -Wnoncanonical-monoid-instances -Wstar-is-type + -Wcompat-unqualified-imports ~~~~~~~~~~ Testing :set -a options currently set: none. base language is: Haskell2010 diff --git a/testsuite/tests/ghci/scripts/ghci024.stdout-mingw32 b/testsuite/tests/ghci/scripts/ghci024.stdout-mingw32 index 8083bc92b0..358f9374a4 100644 --- a/testsuite/tests/ghci/scripts/ghci024.stdout-mingw32 +++ b/testsuite/tests/ghci/scripts/ghci024.stdout-mingw32 @@ -17,6 +17,7 @@ warning settings: -Wsemigroup -Wnoncanonical-monoid-instances -Wstar-is-type + -Wcompat-unqualified-imports ~~~~~~~~~~ Testing :set -a options currently set: none. base language is: Haskell2010 diff --git a/testsuite/tests/ghci/scripts/ghci036.script b/testsuite/tests/ghci/scripts/ghci036.script index 3615e07252..105f147b54 100644 --- a/testsuite/tests/ghci/scripts/ghci036.script +++ b/testsuite/tests/ghci/scripts/ghci036.script @@ -1,3 +1,4 @@ +:set -Wno-compat-unqualified-imports import Data.List (nub) :t nubBy import Data.List (nubBy) @@ -16,4 +17,4 @@ import qualified Data.List as L :m -Data.List :t L.nub :m Prelude -:t nub
\ No newline at end of file +:t nub diff --git a/testsuite/tests/ghci/scripts/ghci038.hs b/testsuite/tests/ghci/scripts/ghci038.hs index 62b3318e25..4e416183eb 100644 --- a/testsuite/tests/ghci/scripts/ghci038.hs +++ b/testsuite/tests/ghci/scripts/ghci038.hs @@ -1,3 +1,3 @@ module Foo where -import Data.List +import Data.List (map) x = map diff --git a/testsuite/tests/ghci/scripts/ghci038.script b/testsuite/tests/ghci/scripts/ghci038.script index c534cfc5b2..db65b5442f 100644 --- a/testsuite/tests/ghci/scripts/ghci038.script +++ b/testsuite/tests/ghci/scripts/ghci038.script @@ -38,9 +38,9 @@ import Prelude () import Prelude :show imports -import Data.List hiding (nub) +import Data.Tuple hiding (swap) :show imports -import qualified Data.List as Q +import qualified Data.Tuple as Q :show imports -:m -Data.List +:m -Data.Tuple :show imports diff --git a/testsuite/tests/ghci/scripts/ghci038.stdout b/testsuite/tests/ghci/scripts/ghci038.stdout index bd13690cca..8a54abb760 100644 --- a/testsuite/tests/ghci/scripts/ghci038.stdout +++ b/testsuite/tests/ghci/scripts/ghci038.stdout @@ -22,10 +22,10 @@ x :: (a -> b) -> [a] -> [b] import Prelude :module +*Foo import Prelude -import Data.List hiding ( nub ) +import Data.Tuple hiding ( swap ) :module +*Foo import Prelude -import Data.List hiding ( nub ) -import qualified Data.List as Q +import Data.Tuple hiding ( swap ) +import qualified Data.Tuple as Q :module +*Foo import Prelude diff --git a/testsuite/tests/ghci/scripts/ghci057.stdout b/testsuite/tests/ghci/scripts/ghci057.stdout index 87b950654d..57820fc4ed 100644 --- a/testsuite/tests/ghci/scripts/ghci057.stdout +++ b/testsuite/tests/ghci/scripts/ghci057.stdout @@ -17,6 +17,7 @@ warning settings: -Wsemigroup -Wnoncanonical-monoid-instances -Wstar-is-type + -Wcompat-unqualified-imports Should fail, GADTs is not enabled options currently set: none. base language is: Haskell2010 @@ -40,6 +41,7 @@ warning settings: -Wsemigroup -Wnoncanonical-monoid-instances -Wstar-is-type + -Wcompat-unqualified-imports Should work, GADTs is in force from :set options currently set: none. base language is: Haskell2010 @@ -62,6 +64,7 @@ warning settings: -Wsemigroup -Wnoncanonical-monoid-instances -Wstar-is-type + -Wcompat-unqualified-imports Should fail, GADTs is now disabled base language is: Haskell2010 with the following modifiers: @@ -86,5 +89,6 @@ warning settings: -Wsemigroup -Wnoncanonical-monoid-instances -Wstar-is-type + -Wcompat-unqualified-imports Should fail, GADTs is only enabled at the prompt C :: T Int diff --git a/testsuite/tests/ghci/scripts/ghci057.stdout-mingw32 b/testsuite/tests/ghci/scripts/ghci057.stdout-mingw32 index eb3e225419..0873022137 100644 --- a/testsuite/tests/ghci/scripts/ghci057.stdout-mingw32 +++ b/testsuite/tests/ghci/scripts/ghci057.stdout-mingw32 @@ -16,6 +16,7 @@ warning settings: -Wsemigroup -Wnoncanonical-monoid-instances -Wstar-is-type + -Wcompat-unqualified-imports Should fail, GADTs is not enabled options currently set: none. base language is: Haskell2010 @@ -38,6 +39,7 @@ warning settings: -Wsemigroup -Wnoncanonical-monoid-instances -Wstar-is-type + -Wcompat-unqualified-imports Should work, GADTs is in force from :set options currently set: none. base language is: Haskell2010 @@ -59,6 +61,7 @@ warning settings: -Wsemigroup -Wnoncanonical-monoid-instances -Wstar-is-type + -Wcompat-unqualified-imports Should fail, GADTs is now disabled base language is: Haskell2010 with the following modifiers: @@ -82,5 +85,6 @@ warning settings: -Wsemigroup -Wnoncanonical-monoid-instances -Wstar-is-type + -Wcompat-unqualified-imports Should fail, GADTs is only enabled at the prompt C :: T Int diff --git a/testsuite/tests/ghci/should_run/ghcirun002.hs b/testsuite/tests/ghci/should_run/ghcirun002.hs index d744359ed1..432712dccc 100644 --- a/testsuite/tests/ghci/should_run/ghcirun002.hs +++ b/testsuite/tests/ghci/should_run/ghcirun002.hs @@ -1,5 +1,5 @@ import Data.Maybe -import Data.List +import Data.List (intersperse) data Dir = R | D | L | U deriving (Show, Eq, Enum) type Spiral = ([[Int]], Int, Dir) -- (rows, current row, next direction) |