From 115cd3c85a8c38f1fe2a10d4ee515f92c96dd5a2 Mon Sep 17 00:00:00 2001 From: Joachim Breitner <mail@joachim-breitner.de> Date: Wed, 10 Mar 2021 15:28:48 -0500 Subject: [PATCH] Use GHC2021 as default language --- compiler/GHC/Driver/Session.hs | 12 +- docs/users_guide/ghci.rst | 9 +- ghc/GHCi/UI.hs | 8 +- libraries/base/tests/IO/hGetChar001.hs | 15 +- libraries/base/tests/IO/misc001.hs | 6 +- libraries/base/tests/IO/newline001.hs | 16 +- libraries/base/tests/T11334a.hs | 1 + libraries/base/tests/T9111.hs | 1 + .../ghc-heap/tests/tso_and_stack_closures.hs | 3 +- .../tests/annotations/should_fail/T10826.hs | 1 + .../annotations/should_fail/T10826.stderr | 10 +- .../tests/backpack/should_compile/T13140.bkp | 1 + .../tests/backpack/should_compile/bkp32.bkp | 1 + .../tests/backpack/should_compile/bkp37.bkp | 1 + .../tests/backpack/should_compile/bkp38.bkp | 1 + .../tests/backpack/should_compile/bkp39.bkp | 1 + .../tests/backpack/should_compile/bkp40.bkp | 1 + .../tests/backpack/should_compile/bkp48.bkp | 1 + .../tests/backpack/should_fail/bkpfail17.bkp | 1 + .../backpack/should_fail/bkpfail17.stderr | 4 +- .../tests/backpack/should_fail/bkpfail23.bkp | 1 + .../backpack/should_fail/bkpfail23.stderr | 2 +- .../tests/backpack/should_fail/bkpfail25.bkp | 1 + .../backpack/should_fail/bkpfail25.stderr | 4 +- .../tests/backpack/should_fail/bkpfail26.bkp | 1 + .../backpack/should_fail/bkpfail26.stderr | 2 +- .../tests/backpack/should_fail/bkpfail28.bkp | 1 + .../backpack/should_fail/bkpfail28.stderr | 12 +- .../tests/backpack/should_fail/bkpfail42.bkp | 1 + .../backpack/should_fail/bkpfail42.stderr | 2 +- .../tests/backpack/should_fail/bkpfail45.bkp | 1 + .../backpack/should_fail/bkpfail45.stderr | 2 +- .../tests/backpack/should_fail/bkpfail46.bkp | 1 + .../backpack/should_fail/bkpfail46.stderr | 2 +- .../tests/backpack/should_fail/bkpfail47.bkp | 1 + .../backpack/should_fail/bkpfail47.stderr | 2 +- .../tests/backpack/should_run/bkprun05.bkp | 1 + .../tests/backpack/should_run/bkprun06.bkp | 1 + testsuite/tests/codeGen/should_run/cas_int.hs | 5 +- .../tests/deSugar/should_compile/T2431.hs | 1 + testsuite/tests/deSugar/should_run/T18151.hs | 1 + .../tests/dependent/should_compile/Dep2.hs | 1 + .../dependent/should_compile/DkNameRes.hs | 1 + .../should_compile/KindEqualities2.hs | 1 + .../dependent/should_compile/RaeBlogPost.hs | 1 + .../dependent/should_compile/RaeJobTalk.hs | 1 + .../tests/dependent/should_compile/T11711.hs | 1 + .../tests/dependent/should_compile/T12442.hs | 1 + .../tests/dependent/should_compile/T14066a.hs | 1 + .../dependent/should_compile/T14066a.stderr | 4 +- .../tests/dependent/should_compile/T14556.hs | 1 + .../tests/dependent/should_compile/T14749.hs | 1 + .../should_compile/T16326_Compile1.hs | 1 + .../dependent/should_compile/TypeLevelVec.hs | 1 + .../dependent/should_compile/dynamic-paper.hs | 1 + .../dependent/should_compile/mkGADTVars.hs | 1 + .../tests/dependent/should_fail/T13601.hs | 1 + .../tests/dependent/should_fail/T13601.stderr | 2 +- .../tests/dependent/should_fail/T13780c.hs | 1 + .../dependent/should_fail/T13780c.stderr | 4 +- .../tests/dependent/should_fail/T15215.hs | 1 + .../tests/dependent/should_fail/T15215.stderr | 4 +- .../tests/dependent/should_fail/T15380.hs | 1 + .../tests/dependent/should_fail/T15380.stderr | 2 +- .../dependent/should_fail/T16326_Fail7.hs | 1 + .../dependent/should_fail/T16326_Fail7.stderr | 2 +- .../tests/deriving/should_compile/T12144_2.hs | 1 + .../tests/deriving/should_compile/T14578.hs | 1 + .../tests/deriving/should_compile/T14579.hs | 1 + .../tests/deriving/should_compile/T14933.hs | 1 + .../tests/deriving/should_compile/T17339.hs | 1 + .../deriving/should_compile/deriving-1935.hs | 1 + .../should_compile/deriving-1935.stderr | 6 +- .../deriving/should_compile/drv-empty-data.hs | 1 + .../drv-foldable-traversable1.hs | 1 + .../drv-foldable-traversable1.stderr | 4 +- .../deriving/should_compile/drv-functor1.hs | 1 + .../should_compile/drv-functor1.stderr | 4 +- .../deriving/should_fail/T10598_fail2.hs | 1 + .../deriving/should_fail/T10598_fail2.stderr | 4 +- .../deriving/should_fail/T10598_fail3.hs | 1 + .../deriving/should_fail/T10598_fail3.stderr | 2 +- .../deriving/should_fail/T10598_fail6.hs | 1 + .../deriving/should_fail/T10598_fail6.stderr | 2 +- .../tests/deriving/should_fail/T10684.hs | 1 + .../tests/deriving/should_fail/T10684.stderr | 2 +- .../tests/deriving/should_fail/T1133A.hs | 1 + .../tests/deriving/should_fail/T1133A.stderr | 12 +- .../tests/deriving/should_fail/T12801.hs | 1 + .../tests/deriving/should_fail/T12801.stderr | 2 +- .../tests/deriving/should_fail/T16181.hs | 1 + .../tests/deriving/should_fail/T16181.stderr | 8 +- .../tests/deriving/should_fail/T1830_1.hs | 1 + .../tests/deriving/should_fail/T1830_1.stderr | 8 +- testsuite/tests/deriving/should_fail/T3833.hs | 1 + .../tests/deriving/should_fail/T3833.stderr | 10 +- testsuite/tests/deriving/should_fail/T3834.hs | 1 + .../tests/deriving/should_fail/T3834.stderr | 10 +- testsuite/tests/deriving/should_fail/T5287.hs | 1 + .../tests/deriving/should_fail/T5287.stderr | 4 +- .../tests/deriving/should_fail/T7401_fail.hs | 1 + .../deriving/should_fail/T7401_fail.stderr | 2 +- testsuite/tests/deriving/should_fail/T8851.hs | 1 + .../tests/deriving/should_fail/T8851.stderr | 20 +- testsuite/tests/deriving/should_fail/T9600.hs | 1 + .../tests/deriving/should_fail/T9600.stderr | 10 +- .../deriving/should_fail/deriving-via-fail.hs | 1 + .../should_fail/deriving-via-fail.stderr | 12 +- .../should_fail/deriving-via-fail4.hs | 1 + .../should_fail/deriving-via-fail4.stderr | 8 +- .../deriving/should_fail/drvfail-functor1.hs | 1 + .../should_fail/drvfail-functor1.stderr | 8 +- .../deriving/should_fail/drvfail-functor2.hs | 1 + .../should_fail/drvfail-functor2.stderr | 48 +-- .../tests/deriving/should_fail/drvfail008.hs | 1 + .../deriving/should_fail/drvfail008.stderr | 2 +- .../tests/deriving/should_fail/drvfail015.hs | 1 + .../deriving/should_fail/drvfail015.stderr | 22 +- testsuite/tests/determinism/determ015/A.hs | 1 + testsuite/tests/ffi/should_fail/T3066.hs | 1 + testsuite/tests/ffi/should_fail/T3066.stderr | 10 +- testsuite/tests/gadt/T1999a.hs | 1 + testsuite/tests/gadt/T3163.hs | 1 + testsuite/tests/gadt/T3163.stderr | 2 +- testsuite/tests/gadt/gadtSyntaxFail001.hs | 1 + testsuite/tests/gadt/gadtSyntaxFail001.stderr | 2 +- testsuite/tests/gadt/gadtSyntaxFail002.hs | 1 + testsuite/tests/gadt/gadtSyntaxFail002.stderr | 2 +- testsuite/tests/gadt/gadtSyntaxFail003.hs | 1 + testsuite/tests/gadt/gadtSyntaxFail003.stderr | 2 +- testsuite/tests/generics/GenShouldFail0.hs | 1 + .../tests/generics/GenShouldFail0.stderr | 8 +- testsuite/tests/generics/GenShouldFail1_0.hs | 1 + .../tests/generics/GenShouldFail1_0.stderr | 8 +- .../T10604/T10604_bad_variable_occurrence.hs | 1 + .../T10604_bad_variable_occurrence.stderr | 2 +- .../generics/T10604/T10604_no_PolyKinds.hs | 1 + .../T10604/T10604_no_PolyKinds.stderr | 2 +- testsuite/tests/generics/T5462No1.hs | 1 + testsuite/tests/generics/T5462No1.stderr | 30 +- testsuite/tests/ghc-api/T7478/T7478.hs | 2 + .../tests/ghc-api/downsweep/OldModLocation.hs | 2 + testsuite/tests/ghci/T18071/T18071.hs | 1 + testsuite/tests/ghci/T18071/T18071.stdout | 2 +- testsuite/tests/ghci/T18262/T18262.hs | 1 + testsuite/tests/ghci/T18262/T18262.stdout | 2 +- testsuite/tests/ghci/prog006/Boot1.hs | 1 + testsuite/tests/ghci/prog006/Boot2.hs | 1 + testsuite/tests/ghci/prog006/prog006.stderr | 2 +- testsuite/tests/ghci/scripts/T12447.script | 1 + testsuite/tests/ghci/scripts/T12550.script | 1 + testsuite/tests/ghci/scripts/T13202a.script | 1 + testsuite/tests/ghci/scripts/T13202a.stderr | 2 +- testsuite/tests/ghci/scripts/T13420.hs | 1 + testsuite/tests/ghci/scripts/T13420.stdout | 2 +- testsuite/tests/ghci/scripts/T14969.script | 1 + testsuite/tests/ghci/scripts/T14969.stderr | 2 +- testsuite/tests/ghci/scripts/T15546.script | 1 + testsuite/tests/ghci/scripts/T15546.stdout | 4 +- testsuite/tests/ghci/scripts/T18501.script | 1 + testsuite/tests/ghci/scripts/T19279.stdout | 4 +- testsuite/tests/ghci/scripts/T4087.hs | 1 + testsuite/tests/ghci/scripts/T4087.stdout | 2 +- testsuite/tests/ghci/scripts/T4175.hs | 1 + testsuite/tests/ghci/scripts/T4175.stdout | 44 +-- testsuite/tests/ghci/scripts/T5417.hs | 1 + testsuite/tests/ghci/scripts/T5417.script | 1 + testsuite/tests/ghci/scripts/T5417.stdout | 2 +- testsuite/tests/ghci/scripts/T5820.hs | 1 + testsuite/tests/ghci/scripts/T5820.stderr | 2 +- testsuite/tests/ghci/scripts/T5820.stdout | 8 +- testsuite/tests/ghci/scripts/T7939.hs | 1 + testsuite/tests/ghci/scripts/T7939.stdout | 14 +- testsuite/tests/ghci/scripts/T9293.hs | 1 + testsuite/tests/ghci/scripts/T9293.script | 1 + testsuite/tests/ghci/scripts/T9293.stderr | 6 +- testsuite/tests/ghci/scripts/T9293.stdout | 8 - testsuite/tests/ghci/scripts/ghci019.hs | 1 + testsuite/tests/ghci/scripts/ghci019.stderr | 2 +- testsuite/tests/ghci/scripts/ghci019.stdout | 4 +- testsuite/tests/ghci/scripts/ghci024.stdout | 14 +- testsuite/tests/ghci/scripts/ghci025.hs | 1 + testsuite/tests/ghci/scripts/ghci057.hs | 1 + testsuite/tests/ghci/scripts/ghci057.script | 1 + testsuite/tests/ghci/scripts/ghci057.stderr | 6 +- testsuite/tests/ghci/scripts/ghci057.stdout | 8 - testsuite/tests/ghci/scripts/ghci064.hs | 1 + testsuite/tests/ghci/scripts/ghci064.stdout | 6 +- testsuite/tests/ghci/scripts/ghci065.stdout | 2 +- .../tests/ghci/should_run/T10857a.stdout | 4 +- .../tests/ghci/should_run/T10857b.stdout | 4 +- testsuite/tests/ghci/should_run/T12525.stdout | 2 +- .../tests/hiefile/should_compile/hie002.hs | 1 + .../should_compile/ClosedFam2.hs | 1 + .../should_compile/ClosedFam2.hs-boot | 1 + .../should_compile/ClosedFam2a.hs | 1 + .../should_compile/IndTypesPerf.hs | 1 + .../should_compile/IndTypesPerfMerge.hs | 1 + .../should_compile/InstEqContext2.hs | 1 + .../indexed-types/should_compile/Roman1.hs | 1 + .../indexed-types/should_compile/Simple14.hs | 1 + .../should_compile/Simple14.stderr | 10 +- .../indexed-types/should_compile/T11361.hs | 1 + .../indexed-types/should_compile/T14554.hs | 1 + .../indexed-types/should_compile/T15122.hs | 1 + .../indexed-types/should_compile/T15352.hs | 1 + .../should_compile/T16110_Compile.hs | 1 + .../should_compile/T16356_Compile1.hs | 1 + .../indexed-types/should_compile/T17008b.hs | 1 + .../indexed-types/should_compile/T4120.hs | 1 + .../indexed-types/should_compile/T4484.hs | 1 + .../indexed-types/should_compile/T5591a.hs | 1 + .../indexed-types/should_compile/T8002.hs | 1 + .../indexed-types/should_compile/T8002a.hs | 1 + .../indexed-types/should_compile/T8002b.hs | 1 + .../indexed-types/should_compile/T8500.hs | 1 + .../indexed-types/should_compile/T8500a.hs | 1 + .../indexed-types/should_compile/T9840.hs | 1 + .../should_compile/T9840.hs-boot | 1 + .../indexed-types/should_compile/T9840a.hs | 1 + .../indexed-types/should_fail/ClosedFam3.hs | 1 + .../should_fail/ClosedFam3.hs-boot | 1 + .../should_fail/ClosedFam3.stderr | 6 +- .../should_fail/ExplicitForAllFams4a.hs | 1 + .../should_fail/ExplicitForAllFams4a.stderr | 4 +- .../should_fail/ExplicitForAllFams4b.hs | 1 + .../should_fail/ExplicitForAllFams4b.stderr | 42 +-- .../indexed-types/should_fail/SimpleFail15.hs | 1 + .../should_fail/SimpleFail15.stderr | 2 +- .../indexed-types/should_fail/SimpleFail4.hs | 1 + .../should_fail/SimpleFail4.stderr | 2 +- .../tests/indexed-types/should_fail/T10899.hs | 1 + .../indexed-types/should_fail/T10899.stderr | 2 +- .../tests/indexed-types/should_fail/T12867.hs | 1 + .../indexed-types/should_fail/T12867.stderr | 4 +- .../tests/indexed-types/should_fail/T14246.hs | 1 + .../indexed-types/should_fail/T14246.stderr | 8 +- .../tests/indexed-types/should_fail/T14887.hs | 1 + .../indexed-types/should_fail/T14887.stderr | 2 +- .../indexed-types/should_fail/T16356_Fail3.hs | 1 + .../should_fail/T16356_Fail3.stderr | 2 +- .../tests/indexed-types/should_fail/T18648.hs | 1 + .../indexed-types/should_fail/T18648.stderr | 4 +- .../tests/indexed-types/should_fail/T1900.hs | 1 + .../indexed-types/should_fail/T1900.stderr | 2 +- .../tests/indexed-types/should_fail/T2664.hs | 1 + .../indexed-types/should_fail/T2664.stderr | 12 +- .../tests/indexed-types/should_fail/T2664a.hs | 1 + .../tests/indexed-types/should_fail/T2888.hs | 1 + .../indexed-types/should_fail/T2888.stderr | 8 +- .../tests/indexed-types/should_fail/T4174.hs | 1 + .../indexed-types/should_fail/T4174.stderr | 6 +- .../tests/indexed-types/should_fail/T4246.hs | 1 + .../indexed-types/should_fail/T4246.stderr | 12 +- .../tests/indexed-types/should_fail/T4485.hs | 1 + .../indexed-types/should_fail/T4485.stderr | 10 +- .../tests/indexed-types/should_fail/T5439.hs | 1 + .../indexed-types/should_fail/T5439.stderr | 12 +- .../tests/indexed-types/should_fail/T9167.hs | 1 + .../indexed-types/should_fail/T9167.stderr | 2 +- testsuite/tests/llvm/should_compile/T11649.hs | 1 + testsuite/tests/llvm/should_compile/T5681.hs | 1 + testsuite/tests/llvm/should_compile/T8131b.hs | 1 + testsuite/tests/module/mod103.hs | 2 + testsuite/tests/module/mod182.hs | 1 + testsuite/tests/module/mod182.stderr | 5 +- testsuite/tests/module/mod39.hs | 1 + testsuite/tests/module/mod39.stderr | 2 +- testsuite/tests/module/mod41.hs | 1 + testsuite/tests/module/mod41.stderr | 14 +- testsuite/tests/module/mod42.hs | 1 + testsuite/tests/module/mod42.stderr | 14 +- testsuite/tests/module/mod43.hs | 1 + testsuite/tests/module/mod43.stderr | 12 +- testsuite/tests/module/mod45.hs | 1 + testsuite/tests/module/mod45.stderr | 10 +- .../parser/should_compile/DumpParsedAst.hs | 1 + .../should_compile/DumpParsedAst.stderr | 214 +++++------ .../parser/should_compile/DumpRenamedAst.hs | 1 + .../should_compile/DumpRenamedAst.stderr | 342 +++++++++--------- .../should_compile/DumpTypecheckedAst.hs | 1 + .../should_compile/DumpTypecheckedAst.stderr | 20 +- .../should_fail/ParserNoBinaryLiterals1.hs | 1 + .../ParserNoBinaryLiterals1.stderr | 4 +- .../should_fail/ParserNoBinaryLiterals2.hs | 1 + .../ParserNoBinaryLiterals2.stderr | 2 +- .../should_fail/ParserNoBinaryLiterals3.hs | 1 + .../ParserNoBinaryLiterals3.stderr | 2 +- .../should_fail/ParserNoForallUnicode.hs | 1 + .../should_fail/ParserNoForallUnicode.stderr | 2 +- .../should_fail/RecordDotSyntaxFail12.hs | 1 + .../should_fail/RecordDotSyntaxFail12.stderr | 22 +- testsuite/tests/parser/should_fail/T12446.hs | 1 + .../tests/parser/should_fail/T12446.stderr | 2 +- testsuite/tests/parser/should_fail/T12811.hs | 1 + .../tests/parser/should_fail/T12811.stderr | 5 +- testsuite/tests/parser/should_fail/T14588.hs | 1 + .../tests/parser/should_fail/T14588.stderr | 2 +- testsuite/tests/parser/should_fail/T16270.hs | 1 + .../tests/parser/should_fail/T16270.stderr | 37 +- testsuite/tests/parser/should_fail/T17162.hs | 1 + .../tests/parser/should_fail/T17162.stderr | 2 +- testsuite/tests/parser/should_fail/T18251c.hs | 1 + .../tests/parser/should_fail/T18251c.stderr | 2 +- testsuite/tests/parser/should_fail/T3095.hs | 1 + .../tests/parser/should_fail/T3095.stderr | 4 +- .../tests/parser/should_fail/T8258NoGADTs.hs | 1 + .../parser/should_fail/T8258NoGADTs.stderr | 2 +- .../tests/parser/should_fail/readFail036.hs | 1 + .../parser/should_fail/readFail036.stderr | 2 +- .../tests/parser/should_fail/readFail037.hs | 1 + .../parser/should_fail/readFail037.stderr | 2 +- .../tests/parser/should_fail/readFail039.hs | 1 + .../parser/should_fail/readFail039.stderr | 10 +- .../parser/should_run/BinaryLiterals0.hs | 1 + .../partial-sigs/should_compile/Meltdown.hs | 1 + .../should_compile/Meltdown.stderr | 8 +- .../NamedWildcardInTypeFamilyInstanceLHS.hs | 1 + .../ScopedNamedWildcardsGood.hs | 1 + .../partial-sigs/should_compile/T10403.hs | 1 + .../partial-sigs/should_compile/T10403.stderr | 18 +- .../should_fail/NamedWildcardsNotEnabled.hs | 1 + .../NamedWildcardsNotEnabled.stderr | 14 +- .../tests/partial-sigs/should_fail/T10615.hs | 1 + .../partial-sigs/should_fail/T10615.stderr | 16 +- .../tests/partial-sigs/should_fail/T12634.hs | 1 + .../partial-sigs/should_fail/T12634.stderr | 6 +- .../tests/patsyn/should_compile/T10997_1.hs | 1 + .../tests/patsyn/should_compile/T10997_1a.hs | 1 + .../tests/patsyn/should_compile/T12698.hs | 1 + .../tests/patsyn/should_compile/T14394.script | 3 +- .../tests/patsyn/should_compile/T14394.stdout | 6 +- testsuite/tests/patsyn/should_fail/T14507.hs | 1 + .../tests/patsyn/should_fail/T14507.stderr | 2 +- testsuite/tests/patsyn/should_fail/T15694.hs | 1 + .../tests/patsyn/should_fail/T15694.stderr | 4 +- testsuite/tests/patsyn/should_fail/T15695.hs | 1 + .../tests/patsyn/should_fail/T15695.stderr | 12 +- testsuite/tests/perf/compiler/T13056.hs | 1 + testsuite/tests/perf/compiler/T14683.hs | 1 + testsuite/tests/perf/compiler/T3064.hs | 1 + testsuite/tests/perf/compiler/T9872a.hs | 1 + testsuite/tests/perf/compiler/T9872a.stderr | 2 +- testsuite/tests/perf/compiler/T9872c.hs | 1 + testsuite/tests/perf/compiler/T9872c.stderr | 2 +- testsuite/tests/perf/should_run/T7257.hs | 5 +- testsuite/tests/plugins/FrontendPlugin.hs | 1 + testsuite/tests/plugins/frontend01.hs | 1 + .../tests/pmcheck/complete_sigs/T14253.hs | 1 + testsuite/tests/polykinds/BadKindVar.hs | 1 + testsuite/tests/polykinds/BadKindVar.stderr | 2 +- testsuite/tests/polykinds/NestedProxies.hs | 1 + testsuite/tests/polykinds/PolyKinds04.hs | 1 + testsuite/tests/polykinds/PolyKinds04.stderr | 12 +- testsuite/tests/polykinds/T10670a.hs | 1 + testsuite/tests/polykinds/T11362.hs | 1 + testsuite/tests/polykinds/T11480a.hs | 1 + testsuite/tests/polykinds/T11480b.hs | 1 + testsuite/tests/polykinds/T11520.hs | 1 + testsuite/tests/polykinds/T11520.stderr | 4 +- testsuite/tests/polykinds/T11523.hs | 1 + testsuite/tests/polykinds/T12055.hs | 1 + testsuite/tests/polykinds/T12055a.hs | 1 + testsuite/tests/polykinds/T12055a.stderr | 2 +- testsuite/tests/polykinds/T14172.hs | 1 + testsuite/tests/polykinds/T14172.stderr | 10 +- testsuite/tests/polykinds/T14270.hs | 1 + testsuite/tests/polykinds/T14450.hs | 1 + testsuite/tests/polykinds/T14450.stderr | 2 +- testsuite/tests/polykinds/T14710.hs | 1 + testsuite/tests/polykinds/T14710.stderr | 12 +- testsuite/tests/polykinds/T15787.hs | 1 + testsuite/tests/polykinds/T15787.stderr | 4 +- testsuite/tests/polykinds/T16244.hs | 1 + testsuite/tests/polykinds/T16244.stderr | 6 +- testsuite/tests/polykinds/T16245.hs | 1 + testsuite/tests/polykinds/T16245.stderr | 6 +- testsuite/tests/polykinds/T16245a.hs | 1 + testsuite/tests/polykinds/T16245a.stderr | 6 +- testsuite/tests/polykinds/T16762b.hs | 1 + testsuite/tests/polykinds/T16762b.stderr | 2 +- testsuite/tests/polykinds/T16902.hs | 1 + testsuite/tests/polykinds/T16902.stderr | 4 +- testsuite/tests/polykinds/T17841.hs | 1 + testsuite/tests/polykinds/T17841.stderr | 4 +- testsuite/tests/polykinds/T6068.hs | 1 + testsuite/tests/polykinds/T6068.script | 1 + testsuite/tests/polykinds/T6137.hs | 1 + testsuite/tests/polykinds/T7053.hs | 1 + testsuite/tests/polykinds/T7053a.hs | 1 + testsuite/tests/polykinds/T7224.hs | 1 + testsuite/tests/polykinds/T7224.stderr | 8 +- testsuite/tests/polykinds/T7805.hs | 1 + testsuite/tests/polykinds/T7805.stderr | 2 +- testsuite/tests/polykinds/T9200.hs | 1 + testsuite/tests/polykinds/TidyClassKinds.hs | 1 + .../tests/polykinds/TidyClassKinds.stderr | 2 +- .../tests/primops/should_compile/T16293a.hs | 1 + .../tests/quantified-constraints/T15359.hs | 1 + .../tests/quantified-constraints/T15359a.hs | 1 + .../tests/quantified-constraints/T18432.hs | 1 + .../tests/rename/should_compile/T1972.hs | 1 + .../tests/rename/should_compile/T1972.stderr | 12 +- .../rename/should_compile/T4003A.hs-boot | 1 + .../tests/rename/should_compile/T4003B.hs | 2 +- .../tests/rename/should_fail/RnFail055.hs | 1 + .../rename/should_fail/RnFail055.hs-boot | 1 + testsuite/tests/rename/should_fail/T11663.hs | 1 + .../tests/rename/should_fail/T11663.stderr | 8 +- testsuite/tests/rename/should_fail/T3265.hs | 1 + .../tests/rename/should_fail/T3265.stderr | 4 +- .../tests/rename/should_fail/rnfail052.hs | 1 + .../tests/rename/should_fail/rnfail052.stderr | 6 +- .../tests/rename/should_fail/rnfail053.hs | 1 + .../tests/rename/should_fail/rnfail053.stderr | 2 +- .../tests/rename/should_fail/rnfail055.stderr | 30 +- .../tests/rename/should_fail/rnfail056.hs | 1 + .../tests/rename/should_fail/rnfail056.stderr | 4 +- .../tests/roles/should_compile/Roles3.hs | 1 + testsuite/tests/roles/should_compile/T8958.hs | 1 + .../tests/roles/should_compile/T8958.stderr | 8 +- testsuite/tests/roles/should_fail/Roles12.hs | 1 + .../tests/roles/should_fail/Roles12.hs-boot | 3 +- .../tests/roles/should_fail/Roles12.stderr | 2 +- testsuite/tests/roles/should_fail/Roles12a.hs | 1 + testsuite/tests/roles/should_fail/T9204.hs | 1 + .../tests/roles/should_fail/T9204.hs-boot | 1 + .../tests/roles/should_fail/T9204.stderr | 2 +- testsuite/tests/roles/should_fail/T9204a.hs | 1 + testsuite/tests/safeHaskell/check/Check01.hs | 1 + .../tests/safeHaskell/check/Check01.stderr | 2 +- .../tests/safeHaskell/check/Check01_A.hs | 1 + .../tests/safeHaskell/check/Check01_B.hs | 1 + testsuite/tests/safeHaskell/check/Check02.hs | 1 + .../tests/safeHaskell/check/Check02_A.hs | 1 + .../tests/safeHaskell/check/Check02_B.hs | 1 + testsuite/tests/safeHaskell/check/Check03.hs | 1 + .../tests/safeHaskell/check/Check03_A.hs | 1 + .../tests/safeHaskell/check/Check03_B.hs | 1 + testsuite/tests/safeHaskell/check/Check04.hs | 1 + .../tests/safeHaskell/check/Check04_A.hs | 1 + .../tests/safeHaskell/check/Check04_B.hs | 1 + testsuite/tests/safeHaskell/check/Check06.hs | 1 + .../tests/safeHaskell/check/Check06_A.hs | 1 + testsuite/tests/safeHaskell/check/Check08.hs | 1 + .../tests/safeHaskell/check/Check08.stderr | 2 +- .../tests/safeHaskell/check/Check08_A.hs | 1 + .../tests/safeHaskell/check/Check08_B.hs | 1 + testsuite/tests/safeHaskell/check/Check09.hs | 1 + .../tests/safeHaskell/check/Check09.stderr | 8 +- testsuite/tests/safeHaskell/check/Check10.hs | 1 + testsuite/tests/safeHaskell/check/CheckB.hs | 1 + .../safeHaskell/check/pkg01/ImpSafe01.hs | 1 + .../safeHaskell/check/pkg01/ImpSafe01.stderr | 4 +- .../safeHaskell/check/pkg01/ImpSafe02.hs | 1 + .../safeHaskell/check/pkg01/ImpSafe03.hs | 1 + .../safeHaskell/check/pkg01/ImpSafe03_A.hs | 1 + .../safeHaskell/check/pkg01/ImpSafe04.hs | 1 + .../safeHaskell/check/pkg01/ImpSafe04.stderr | 4 +- .../safeHaskell/check/pkg01/ImpSafeOnly01.hs | 1 + .../safeHaskell/check/pkg01/ImpSafeOnly02.hs | 1 + .../safeHaskell/check/pkg01/ImpSafeOnly03.hs | 1 + .../check/pkg01/ImpSafeOnly03.stderr | 2 +- .../safeHaskell/check/pkg01/ImpSafeOnly04.hs | 1 + .../safeHaskell/check/pkg01/ImpSafeOnly05.hs | 1 + .../check/pkg01/ImpSafeOnly05.stderr | 2 +- .../safeHaskell/check/pkg01/ImpSafeOnly06.hs | 1 + .../safeHaskell/check/pkg01/ImpSafeOnly07.hs | 1 + .../safeHaskell/check/pkg01/ImpSafeOnly08.hs | 1 + .../safeHaskell/check/pkg01/ImpSafeOnly09.hs | 1 + testsuite/tests/safeHaskell/flags/Flags02.hs | 1 + .../tests/safeHaskell/flags/SafeFlags01.hs | 1 + .../tests/safeHaskell/flags/SafeFlags11.hs | 1 + .../tests/safeHaskell/flags/SafeFlags17.hs | 1 + .../safeHaskell/flags/SafeFlags17.stderr | 4 +- .../tests/safeHaskell/flags/SafeFlags20.hs | 1 + .../tests/safeHaskell/flags/SafeFlags21.hs | 1 + .../tests/safeHaskell/flags/SafeFlags22.hs | 1 + .../safeHaskell/flags/SafeFlags22.stderr | 4 +- .../tests/safeHaskell/flags/SafeFlags23.hs | 1 + .../safeHaskell/flags/SafeFlags23.stderr | 4 +- .../tests/safeHaskell/flags/SafeFlags25.hs | 1 + .../safeHaskell/flags/SafeFlags25.stderr | 2 +- .../tests/safeHaskell/flags/SafeFlags26.hs | 1 + .../safeHaskell/flags/SafeFlags26.stderr | 2 +- testsuite/tests/safeHaskell/flags/all.T | 4 +- testsuite/tests/safeHaskell/ghci/all.T | 2 +- testsuite/tests/safeHaskell/ghci/p1.script | 1 + testsuite/tests/safeHaskell/ghci/p10.script | 1 + testsuite/tests/safeHaskell/ghci/p10.stderr | 2 +- testsuite/tests/safeHaskell/ghci/p11.script | 1 + testsuite/tests/safeHaskell/ghci/p12.script | 1 + testsuite/tests/safeHaskell/ghci/p13.script | 1 + testsuite/tests/safeHaskell/ghci/p13.stderr | 24 +- testsuite/tests/safeHaskell/ghci/p14.script | 1 + testsuite/tests/safeHaskell/ghci/p14.stderr | 2 +- testsuite/tests/safeHaskell/ghci/p16.script | 1 + testsuite/tests/safeHaskell/ghci/p16.stderr | 8 +- testsuite/tests/safeHaskell/ghci/p17.script | 1 + testsuite/tests/safeHaskell/ghci/p2.script | 1 + testsuite/tests/safeHaskell/ghci/p3.script | 2 + testsuite/tests/safeHaskell/ghci/p4.script | 1 + testsuite/tests/safeHaskell/ghci/p4.stderr | 7 +- testsuite/tests/safeHaskell/ghci/p5.script | 1 + testsuite/tests/safeHaskell/ghci/p6.script | 1 + testsuite/tests/safeHaskell/ghci/p6.stderr | 6 +- testsuite/tests/safeHaskell/ghci/p7.script | 2 + testsuite/tests/safeHaskell/ghci/p8.script | 1 + testsuite/tests/safeHaskell/ghci/p9.script | 1 + testsuite/tests/safeHaskell/ghci/p9.stderr | 2 +- .../safeHaskell/overlapping/SH_Overlap1.hs | 1 + .../overlapping/SH_Overlap1.stderr | 23 +- .../safeHaskell/overlapping/SH_Overlap10.hs | 1 + .../safeHaskell/overlapping/SH_Overlap10_A.hs | 1 + .../safeHaskell/overlapping/SH_Overlap10_B.hs | 1 + .../safeHaskell/overlapping/SH_Overlap11.hs | 1 + .../overlapping/SH_Overlap11.stderr | 8 +- .../safeHaskell/overlapping/SH_Overlap11_A.hs | 1 + .../safeHaskell/overlapping/SH_Overlap11_B.hs | 1 + .../safeHaskell/overlapping/SH_Overlap1_A.hs | 1 + .../safeHaskell/overlapping/SH_Overlap1_B.hs | 1 + .../safeHaskell/overlapping/SH_Overlap2.hs | 1 + .../overlapping/SH_Overlap2.stderr | 23 +- .../safeHaskell/overlapping/SH_Overlap2_A.hs | 1 + .../safeHaskell/overlapping/SH_Overlap2_B.hs | 1 + .../safeHaskell/overlapping/SH_Overlap3.hs | 1 + .../safeHaskell/overlapping/SH_Overlap3_A.hs | 1 + .../safeHaskell/overlapping/SH_Overlap3_B.hs | 1 + .../safeHaskell/overlapping/SH_Overlap4.hs | 1 + .../safeHaskell/overlapping/SH_Overlap4_A.hs | 1 + .../safeHaskell/overlapping/SH_Overlap4_B.hs | 1 + .../safeHaskell/overlapping/SH_Overlap5.hs | 1 + .../overlapping/SH_Overlap5.stderr | 23 +- .../safeHaskell/overlapping/SH_Overlap5_A.hs | 1 + .../safeHaskell/overlapping/SH_Overlap5_B.hs | 1 + .../safeHaskell/overlapping/SH_Overlap6.hs | 1 + .../overlapping/SH_Overlap6.stderr | 23 +- .../safeHaskell/overlapping/SH_Overlap6_A.hs | 1 + .../safeHaskell/overlapping/SH_Overlap6_B.hs | 1 + .../safeHaskell/overlapping/SH_Overlap7.hs | 1 + .../overlapping/SH_Overlap7.stderr | 8 +- .../safeHaskell/overlapping/SH_Overlap7_A.hs | 1 + .../safeHaskell/overlapping/SH_Overlap7_B.hs | 1 + .../safeHaskell/overlapping/SH_Overlap8.hs | 1 + .../safeHaskell/overlapping/SH_Overlap8_A.hs | 1 + .../safeHaskell/overlapping/SH_Overlap9.hs | 1 + .../safeHaskell/overlapping/SH_Overlap9_A.hs | 1 + .../safeHaskell/overlapping/SH_Overlap9_B.hs | 1 + .../tests/safeHaskell/safeInfered/Mixed02.hs | 1 + .../safeHaskell/safeInfered/Mixed02.stderr | 2 +- .../tests/safeHaskell/safeInfered/Mixed03.hs | 1 + .../safeHaskell/safeInfered/Mixed03.stderr | 2 +- .../safeHaskell/safeInfered/SafeInfered01.hs | 1 + .../safeInfered/SafeInfered01_A.hs | 1 + .../safeHaskell/safeInfered/SafeInfered02.hs | 1 + .../safeInfered/SafeInfered02_A.hs | 1 + .../safeHaskell/safeInfered/SafeInfered03.hs | 1 + .../safeInfered/SafeInfered03_A.hs | 1 + .../safeHaskell/safeInfered/SafeInfered04.hs | 1 + .../safeInfered/SafeInfered04_A.hs | 1 + .../safeHaskell/safeInfered/SafeInfered05.hs | 1 + .../safeInfered/SafeInfered05.stderr | 4 +- .../safeInfered/SafeInfered05_A.hs | 1 + .../safeHaskell/safeInfered/SafeWarn01.hs | 1 + .../safeHaskell/safeInfered/SafeWarn01.stderr | 2 +- .../tests/safeHaskell/safeInfered/T16689.hs | 1 + .../safeInfered/TrustworthySafe02.hs | 1 + .../safeInfered/TrustworthySafe02.stderr | 2 +- .../safeInfered/TrustworthySafe03.hs | 1 + .../safeInfered/TrustworthySafe03.stderr | 2 +- .../safeInfered/UnsafeInfered01.hs | 1 + .../safeInfered/UnsafeInfered01.stderr | 2 +- .../safeInfered/UnsafeInfered02.hs | 1 + .../safeInfered/UnsafeInfered02.stderr | 2 +- .../safeInfered/UnsafeInfered03.hs | 1 + .../safeInfered/UnsafeInfered03.stderr | 2 +- .../safeInfered/UnsafeInfered05.hs | 1 + .../safeInfered/UnsafeInfered05.stderr | 2 +- .../safeInfered/UnsafeInfered06.hs | 1 + .../safeInfered/UnsafeInfered06.stderr | 2 +- .../safeInfered/UnsafeInfered08.hs | 1 + .../safeInfered/UnsafeInfered08_A.hs | 1 + .../safeInfered/UnsafeInfered09.hs | 1 + .../safeInfered/UnsafeInfered09.stderr | 2 +- .../safeInfered/UnsafeInfered10.hs | 1 + .../safeInfered/UnsafeInfered10.stderr | 2 +- .../safeInfered/UnsafeInfered11.hs | 1 + .../safeInfered/UnsafeInfered11.stderr | 6 +- .../safeInfered/UnsafeInfered11_A.hs | 1 + .../safeInfered/UnsafeInfered12.hs | 1 + .../safeInfered/UnsafeInfered12.stderr | 4 +- .../safeInfered/UnsafeInfered13.hs | 1 + .../safeInfered/UnsafeInfered14.hs | 1 + .../safeInfered/UnsafeInfered15.hs | 1 + .../safeInfered/UnsafeInfered16.hs | 1 + .../safeInfered/UnsafeInfered17.hs | 1 + .../safeInfered/UnsafeInfered18.hs | 1 + .../safeInfered/UnsafeInfered18.stderr | 2 +- .../safeInfered/UnsafeInfered19.hs | 1 + .../safeHaskell/safeInfered/UnsafeWarn01.hs | 1 + .../safeInfered/UnsafeWarn01.stderr | 4 +- .../safeHaskell/safeInfered/UnsafeWarn02.hs | 1 + .../safeInfered/UnsafeWarn02.stderr | 4 +- .../safeHaskell/safeInfered/UnsafeWarn03.hs | 1 + .../safeInfered/UnsafeWarn03.stderr | 4 +- .../safeHaskell/safeInfered/UnsafeWarn04.hs | 1 + .../safeInfered/UnsafeWarn04.stderr | 4 +- .../safeHaskell/safeInfered/UnsafeWarn05.hs | 1 + .../safeInfered/UnsafeWarn05.stderr | 8 +- .../safeHaskell/safeInfered/UnsafeWarn06.hs | 1 + .../safeInfered/UnsafeWarn06.stderr | 4 +- .../safeHaskell/safeInfered/UnsafeWarn07.hs | 1 + .../safeInfered/UnsafeWarn07.stderr | 4 +- .../safeHaskell/safeLanguage/SafeLang01.hs | 1 + .../safeLanguage/SafeLang01.stderr | 4 +- .../safeHaskell/safeLanguage/SafeLang03.hs | 1 + .../safeLanguage/SafeLang03.stderr | 2 +- .../safeHaskell/safeLanguage/SafeLang08.hs | 1 + .../safeLanguage/SafeLang08.stderr | 12 +- .../safeHaskell/safeLanguage/SafeLang10.hs | 1 + .../safeLanguage/SafeLang10.stderr | 32 +- .../safeHaskell/safeLanguage/SafeLang10_A.hs | 1 + .../safeHaskell/safeLanguage/SafeLang10_B.hs | 1 + .../safeHaskell/safeLanguage/SafeLang12.hs | 1 + .../safeLanguage/SafeLang12.stderr | 4 +- .../safeHaskell/safeLanguage/SafeLang12_A.hs | 1 + .../safeHaskell/safeLanguage/SafeLang12_B.hs | 1 + .../safeHaskell/safeLanguage/SafeLang16.hs | 1 + .../safeLanguage/SafeLang16.stderr | 4 +- .../safeHaskell/safeLanguage/SafeLang17.hs | 1 + .../safeLanguage/SafeLang17.stderr | 32 +- .../safeHaskell/safeLanguage/SafeLang17_A.hs | 1 + .../safeHaskell/safeLanguage/SafeLang17_B.hs | 1 + .../safeHaskell/safeLanguage/SafeLang18.hs | 1 + .../safeHaskell/unsafeLibs/BadImport01.hs | 1 + .../safeHaskell/unsafeLibs/BadImport01.stderr | 2 +- .../safeHaskell/unsafeLibs/BadImport06.hs | 1 + .../safeHaskell/unsafeLibs/BadImport06.stderr | 2 +- .../safeHaskell/unsafeLibs/BadImport07.hs | 1 + .../safeHaskell/unsafeLibs/BadImport07.stderr | 2 +- .../safeHaskell/unsafeLibs/BadImport08.hs | 1 + .../safeHaskell/unsafeLibs/BadImport08.stderr | 2 +- .../safeHaskell/unsafeLibs/BadImport09.hs | 1 + .../safeHaskell/unsafeLibs/BadImport09.stderr | 2 +- .../tests/safeHaskell/unsafeLibs/Dep05.hs | 1 + .../tests/safeHaskell/unsafeLibs/Dep05.stderr | 2 +- .../tests/safeHaskell/unsafeLibs/Dep06.hs | 1 + .../tests/safeHaskell/unsafeLibs/Dep06.stderr | 2 +- .../tests/safeHaskell/unsafeLibs/Dep07.hs | 1 + .../tests/safeHaskell/unsafeLibs/Dep07.stderr | 2 +- .../tests/safeHaskell/unsafeLibs/Dep08.hs | 1 + .../tests/safeHaskell/unsafeLibs/Dep08.stderr | 2 +- .../tests/safeHaskell/unsafeLibs/Dep09.hs | 1 + .../tests/safeHaskell/unsafeLibs/Dep09.stderr | 2 +- .../tests/safeHaskell/unsafeLibs/Dep10.hs | 1 + .../tests/safeHaskell/unsafeLibs/Dep10.stderr | 2 +- .../safeHaskell/unsafeLibs/GoodImport01.hs | 1 + .../safeHaskell/unsafeLibs/GoodImport02.hs | 1 + .../safeHaskell/unsafeLibs/GoodImport03.hs | 1 + .../tests/saks/should_fail/saks_fail001.hs | 1 + .../saks/should_fail/saks_fail001.stderr | 2 +- .../tests/simplCore/should_compile/T14270a.hs | 1 + .../simplCore/should_compile/T16038/A.hs | 1 + .../simplCore/should_compile/T16038/A.hs-boot | 1 + .../simplCore/should_compile/T16038/B.hs | 1 + .../tests/simplCore/should_compile/T16979b.hs | 1 + .../tests/simplCore/should_compile/T5329.hs | 1 + .../simplCore/should_compile/T8331.stderr | 2 +- .../tests/simplCore/should_compile/rule2.hs | 1 + testsuite/tests/simplCore/should_run/T5315.hs | 1 + testsuite/tests/simplCore/should_run/runST.hs | 7 +- .../tests/stranal/should_compile/T8743.hs | 1 + .../stranal/should_compile/T8743.hs-boot | 1 + .../tests/stranal/should_compile/T8743a.hs | 1 + testsuite/tests/th/ClosedFam2TH.hs | 1 + testsuite/tests/th/T10811.hs | 1 + testsuite/tests/th/T10820.hs | 1 + testsuite/tests/th/T10891.hs | 1 + testsuite/tests/th/T11721_TH.hs | 1 + testsuite/tests/th/T12045TH1.hs | 1 + testsuite/tests/th/T12045TH1.stderr | 8 +- testsuite/tests/th/T12045TH2.hs | 1 + testsuite/tests/th/T12411.hs | 1 + testsuite/tests/th/T12411.stderr | 4 +- testsuite/tests/th/T12646.hs | 1 + testsuite/tests/th/T15243.hs | 1 + testsuite/tests/th/T15243.stderr | 2 +- testsuite/tests/th/T16133.hs | 1 + testsuite/tests/th/T16133.stderr | 5 +- testsuite/tests/th/T16976.hs | 1 + testsuite/tests/th/T18388.hs | 1 + testsuite/tests/th/TH_Roles4.hs | 1 + .../tests/th/TH_reifyExplicitForAllFams.hs | 1 + .../typecheck/should_compile/LocalGivenEqs.hs | 1 + .../tests/typecheck/should_compile/SplitWD.hs | 1 + .../tests/typecheck/should_compile/T11524.hs | 1 + .../tests/typecheck/should_compile/T11811.hs | 1 + .../tests/typecheck/should_compile/T12919.hs | 1 + .../tests/typecheck/should_compile/T13333.hs | 1 + .../tests/typecheck/should_compile/T13651.hs | 1 + .../typecheck/should_compile/T13651.stderr | 4 +- .../tests/typecheck/should_compile/T13651a.hs | 1 + .../tests/typecheck/should_compile/T13822.hs | 1 + .../tests/typecheck/should_compile/T13871.hs | 1 + .../tests/typecheck/should_compile/T13879.hs | 1 + .../tests/typecheck/should_compile/T14366.hs | 1 + .../tests/typecheck/should_compile/T14451.hs | 1 + .../typecheck/should_compile/T14590.stderr | 4 +- .../tests/typecheck/should_compile/T14735.hs | 1 + .../tests/typecheck/should_compile/T14763.hs | 1 + .../tests/typecheck/should_compile/T15079.hs | 1 + .../tests/typecheck/should_compile/T17202.hs | 1 + .../tests/typecheck/should_compile/T17562b.hs | 1 + .../should_compile/T17567StupidThetaB.hs | 1 + .../should_compile/T17567StupidThetaB.stderr | 2 +- .../tests/typecheck/should_compile/T4355.hs | 1 + .../typecheck/should_compile/T4355.stderr | 2 +- .../tests/typecheck/should_compile/T4524.hs | 1 + .../tests/typecheck/should_compile/T5490.hs | 1 + .../typecheck/should_compile/T5490.stderr | 2 +- .../tests/typecheck/should_compile/T6018.hs | 1 + .../typecheck/should_compile/T6018.stderr | 8 +- .../tests/typecheck/should_compile/T7503a.hs | 1 + .../tests/typecheck/should_compile/T9151.hs | 1 + .../typecheck/should_compile/Tc251_Help.hs | 1 + .../tests/typecheck/should_compile/Tc271.hs | 1 + .../typecheck/should_compile/Tc271.hs-boot | 1 + .../tests/typecheck/should_compile/Tc271a.hs | 1 + .../tests/typecheck/should_compile/tc146.hs | 1 + .../tests/typecheck/should_compile/tc153.hs | 1 + .../tests/typecheck/should_compile/tc231.hs | 1 + .../tests/typecheck/should_compile/tc250.hs | 1 + .../tests/typecheck/should_compile/tc251.hs | 1 + .../tests/typecheck/should_compile/tc252.hs | 1 + .../tests/typecheck/should_compile/tc253.hs | 1 + .../typecheck/should_fail/AssocTyDef02.hs | 1 + .../typecheck/should_fail/AssocTyDef02.stderr | 2 +- .../typecheck/should_fail/LevPolyBounded.hs | 1 + .../should_fail/LevPolyBounded.stderr | 8 +- .../tests/typecheck/should_fail/T10351.hs | 1 + .../tests/typecheck/should_fail/T10351.stderr | 2 +- .../tests/typecheck/should_fail/T11563.hs | 1 + .../tests/typecheck/should_fail/T11563.stderr | 2 +- .../tests/typecheck/should_fail/T12083a.hs | 1 + .../typecheck/should_fail/T12083a.stderr | 4 +- .../tests/typecheck/should_fail/T12083b.hs | 1 + .../typecheck/should_fail/T12083b.stderr | 2 +- .../tests/typecheck/should_fail/T12430.hs | 1 + .../tests/typecheck/should_fail/T12430.stderr | 4 +- .../tests/typecheck/should_fail/T12563.hs | 1 + .../tests/typecheck/should_fail/T12563.stderr | 6 +- .../tests/typecheck/should_fail/T12785b.hs | 1 + .../typecheck/should_fail/T12785b.stderr | 12 +- .../tests/typecheck/should_fail/T14618.hs | 1 + .../tests/typecheck/should_fail/T14618.stderr | 6 +- .../tests/typecheck/should_fail/T14904a.hs | 1 + .../typecheck/should_fail/T14904a.stderr | 4 +- .../tests/typecheck/should_fail/T15527.hs | 1 + .../tests/typecheck/should_fail/T15527.stderr | 2 +- .../tests/typecheck/should_fail/T15552a.hs | 1 + .../typecheck/should_fail/T15552a.stderr | 7 +- .../tests/typecheck/should_fail/T15712.hs | 1 + .../tests/typecheck/should_fail/T15712.stderr | 2 +- .../tests/typecheck/should_fail/T16059c.hs | 1 + .../typecheck/should_fail/T16059c.stderr | 2 +- .../tests/typecheck/should_fail/T16059e.hs | 1 + .../typecheck/should_fail/T16059e.stderr | 2 +- .../tests/typecheck/should_fail/T16255.hs | 1 + .../tests/typecheck/should_fail/T16255.stderr | 4 +- .../tests/typecheck/should_fail/T16414.hs | 1 + .../tests/typecheck/should_fail/T16414.stderr | 6 +- .../tests/typecheck/should_fail/T16502.hs | 1 + .../tests/typecheck/should_fail/T17213.hs | 1 + .../tests/typecheck/should_fail/T17213.stderr | 2 +- .../tests/typecheck/should_fail/T17563.hs | 1 + .../tests/typecheck/should_fail/T17563.stderr | 2 +- .../typecheck/should_fail/T18939_Fail.hs | 1 + .../typecheck/should_fail/T18939_Fail.stderr | 2 +- .../tests/typecheck/should_fail/T19109.hs | 1 + .../tests/typecheck/should_fail/T19109.stderr | 2 +- .../tests/typecheck/should_fail/T19187.hs | 1 + .../tests/typecheck/should_fail/T19187.stderr | 2 +- .../tests/typecheck/should_fail/T2247.hs | 1 + .../tests/typecheck/should_fail/T2247.stderr | 14 +- .../tests/typecheck/should_fail/T2538.hs | 1 + .../tests/typecheck/should_fail/T2538.stderr | 6 +- .../tests/typecheck/should_fail/T2994.hs | 1 + .../tests/typecheck/should_fail/T2994.stderr | 8 +- .../tests/typecheck/should_fail/T3155.hs | 1 + .../tests/typecheck/should_fail/T3155.stderr | 2 +- .../tests/typecheck/should_fail/T3468.hs | 1 + .../tests/typecheck/should_fail/T3950.hs | 1 + .../tests/typecheck/should_fail/T3950.stderr | 4 +- .../tests/typecheck/should_fail/T5300.hs | 1 + .../tests/typecheck/should_fail/T5300.stderr | 8 +- .../tests/typecheck/should_fail/T5957.hs | 1 + .../tests/typecheck/should_fail/T5957.stderr | 5 +- .../tests/typecheck/should_fail/T6022.hs | 1 + .../tests/typecheck/should_fail/T6022.stderr | 2 +- .../tests/typecheck/should_fail/T6069.stderr | 2 +- .../tests/typecheck/should_fail/T8034.hs | 1 + .../tests/typecheck/should_fail/T8034.stderr | 2 +- .../tests/typecheck/should_fail/T8883.hs | 1 + .../tests/typecheck/should_fail/T8883.stderr | 2 +- .../tests/typecheck/should_fail/T9201.hs | 1 + .../tests/typecheck/should_fail/T9201.stderr | 6 +- .../tests/typecheck/should_fail/T9858a.hs | 1 + .../tests/typecheck/should_fail/T9858a.stderr | 2 +- .../typecheck/should_fail/TcNoNullaryTC.hs | 1 + .../should_fail/TcNoNullaryTC.stderr | 2 +- .../tests/typecheck/should_fail/tcfail044.hs | 1 + .../typecheck/should_fail/tcfail044.stderr | 28 +- .../tests/typecheck/should_fail/tcfail047.hs | 1 + .../typecheck/should_fail/tcfail047.stderr | 14 +- .../tests/typecheck/should_fail/tcfail076.hs | 1 + .../typecheck/should_fail/tcfail076.stderr | 10 +- .../tests/typecheck/should_fail/tcfail098.hs | 1 + .../typecheck/should_fail/tcfail098.stderr | 4 +- .../tests/typecheck/should_fail/tcfail116.hs | 1 + .../typecheck/should_fail/tcfail116.stderr | 4 +- .../tests/typecheck/should_fail/tcfail117.hs | 1 + .../typecheck/should_fail/tcfail117.stderr | 22 +- .../tests/typecheck/should_fail/tcfail122.hs | 1 + .../typecheck/should_fail/tcfail122.stderr | 4 +- .../tests/typecheck/should_fail/tcfail132.hs | 1 + .../typecheck/should_fail/tcfail132.stderr | 4 +- .../tests/typecheck/should_fail/tcfail139.hs | 1 + .../typecheck/should_fail/tcfail139.stderr | 12 +- .../tests/typecheck/should_fail/tcfail140.hs | 1 + .../typecheck/should_fail/tcfail140.stderr | 18 +- .../tests/typecheck/should_fail/tcfail142.hs | 1 + .../typecheck/should_fail/tcfail142.stderr | 4 +- .../tests/typecheck/should_fail/tcfail143.hs | 1 + .../typecheck/should_fail/tcfail143.stderr | 4 +- .../tests/typecheck/should_fail/tcfail150.hs | 1 + .../typecheck/should_fail/tcfail150.stderr | 2 +- .../tests/typecheck/should_fail/tcfail154.hs | 1 + .../typecheck/should_fail/tcfail154.stderr | 2 +- .../tests/typecheck/should_fail/tcfail158.hs | 1 + .../typecheck/should_fail/tcfail158.stderr | 2 +- .../tests/typecheck/should_fail/tcfail166.hs | 1 + .../typecheck/should_fail/tcfail166.stderr | 2 +- .../tests/typecheck/should_fail/tcfail173.hs | 1 + .../typecheck/should_fail/tcfail173.stderr | 2 +- .../tests/typecheck/should_fail/tcfail183.hs | 1 + .../typecheck/should_fail/tcfail183.stderr | 2 +- .../tests/typecheck/should_fail/tcfail184.hs | 1 + .../typecheck/should_fail/tcfail184.stderr | 2 +- .../tests/typecheck/should_fail/tcfail195.hs | 1 + .../typecheck/should_fail/tcfail195.stderr | 2 +- .../tests/typecheck/should_fail/tcfail209.hs | 1 + .../typecheck/should_fail/tcfail209.stderr | 2 +- .../tests/typecheck/should_fail/tcfail209a.hs | 1 + .../typecheck/should_fail/tcfail209a.stderr | 5 +- .../tests/typecheck/should_run/TypeOf.hs | 1 + 855 files changed, 1774 insertions(+), 1246 deletions(-) diff --git a/compiler/GHC/Driver/Session.hs b/compiler/GHC/Driver/Session.hs index b4218d29baf8..f33373b130f6 100644 --- a/compiler/GHC/Driver/Session.hs +++ b/compiler/GHC/Driver/Session.hs @@ -267,7 +267,7 @@ import Control.Monad.Trans.Except import Data.Ord import Data.Char -import Data.List (intercalate, delete, sortBy) +import Data.List (intercalate, sortBy) import qualified Data.Set as Set import System.FilePath import System.Directory @@ -1309,14 +1309,8 @@ flattenExtensionFlags ml = foldr f defaultExtensionFlags -- @docs/users_guide/exts@. languageExtensions :: Maybe Language -> [LangExt.Extension] -languageExtensions Nothing - -- Nothing => the default case - = LangExt.NondecreasingIndentation -- This has been on by default for some time - : delete LangExt.DatatypeContexts -- The Haskell' committee decided to - -- remove datatype contexts from the - -- language: - -- http://www.haskell.org/pipermail/haskell-prime/2011-January/003335.html - (languageExtensions (Just Haskell2010)) +-- Nothing: the default case +languageExtensions Nothing = languageExtensions (Just GHC2021) languageExtensions (Just Haskell98) = [LangExt.ImplicitPrelude, diff --git a/docs/users_guide/ghci.rst b/docs/users_guide/ghci.rst index f32692f4725c..ac9f33f362f8 100644 --- a/docs/users_guide/ghci.rst +++ b/docs/users_guide/ghci.rst @@ -3204,14 +3204,15 @@ clean GHCi session we might see something like this: .. code-block:: none ghci> :seti - base language is: Haskell2010 + base language is: GHC2021 with the following modifiers: - -XNoMonomorphismRestriction - -XNoDatatypeContexts - -XNondecreasingIndentation -XExtendedDefaultRules + -XNoMonomorphismRestriction GHCi-specific dynamic flag settings: other dynamic, non-language, flag settings: + -fexternal-dynamic-refs + -fignore-optim-changes + -fignore-hpc-changes -fimplicit-import-qualified warning settings: diff --git a/ghc/GHCi/UI.hs b/ghc/GHCi/UI.hs index 720f57a4e34a..10a9cfa71d2a 100644 --- a/ghc/GHCi/UI.hs +++ b/ghc/GHCi/UI.hs @@ -3367,10 +3367,10 @@ showLanguages' show_all dflags = quiet = not show_all && test f default_dflags == is_on default_dflags = - defaultDynFlags (settings dflags) (llvmConfig dflags) `lang_set` - case language dflags of - Nothing -> Just Haskell2010 - other -> other + defaultDynFlags (settings dflags) (llvmConfig dflags) `lang_set` Just lang + + lang = fromMaybe GHC2021 (language dflags) + showTargets :: GHC.GhcMonad m => m () showTargets = mapM_ showTarget =<< GHC.getTargets diff --git a/libraries/base/tests/IO/hGetChar001.hs b/libraries/base/tests/IO/hGetChar001.hs index 776c88eb09c2..f1cd80e6a24d 100644 --- a/libraries/base/tests/IO/hGetChar001.hs +++ b/libraries/base/tests/IO/hGetChar001.hs @@ -10,9 +10,12 @@ main = do where readLine = do eof <- isEOF - if eof then return [] else do - c <- getChar - if c `elem` ['\n','\r'] - then return [] - else do cs <- readLine - return (c:cs) + if eof + then return [] + else do + c <- getChar + if c `elem` ['\n','\r'] + then return [] + else do + cs <- readLine + return (c:cs) diff --git a/libraries/base/tests/IO/misc001.hs b/libraries/base/tests/IO/misc001.hs index 4e0bbecbaee9..047152ed55d7 100644 --- a/libraries/base/tests/IO/misc001.hs +++ b/libraries/base/tests/IO/misc001.hs @@ -19,6 +19,6 @@ copyFile h1 h2 = do if eof then return () else do - c <- hGetChar h1 - c <- hPutChar h2 (toUpper c) - copyFile h1 h2 + c <- hGetChar h1 + c <- hPutChar h2 (toUpper c) + copyFile h1 h2 diff --git a/libraries/base/tests/IO/newline001.hs b/libraries/base/tests/IO/newline001.hs index 1c894422a9e6..a40947921b7d 100644 --- a/libraries/base/tests/IO/newline001.hs +++ b/libraries/base/tests/IO/newline001.hs @@ -108,14 +108,18 @@ read_chars :: Handle -> IO String read_chars h = loop h "" where loop h acc = do b <- hIsEOF h - if b then return (reverse acc) else do - c <- hGetChar h - loop h (c:acc) + if b + then return (reverse acc) + else do + c <- hGetChar h + loop h (c:acc) read_lines :: Handle -> IO String read_lines h = loop h [] where loop h acc = do b <- hIsEOF h - if b then return (intercalate "\n" (reverse acc)) else do - l <- hGetLine h - loop h (l : acc) + if b + then return (intercalate "\n" (reverse acc)) + else do + l <- hGetLine h + loop h (l : acc) diff --git a/libraries/base/tests/T11334a.hs b/libraries/base/tests/T11334a.hs index ad296967a7c0..16ca6408153d 100644 --- a/libraries/base/tests/T11334a.hs +++ b/libraries/base/tests/T11334a.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE DataKinds #-} module Main (main) where diff --git a/libraries/base/tests/T9111.hs b/libraries/base/tests/T9111.hs index b2d1716ccdb8..66e5c4a5e2b0 100644 --- a/libraries/base/tests/T9111.hs +++ b/libraries/base/tests/T9111.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE DataKinds #-} module T9111 where diff --git a/libraries/ghc-heap/tests/tso_and_stack_closures.hs b/libraries/ghc-heap/tests/tso_and_stack_closures.hs index 313076f89027..a845f844b37d 100644 --- a/libraries/ghc-heap/tests/tso_and_stack_closures.hs +++ b/libraries/ghc-heap/tests/tso_and_stack_closures.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE NondecreasingIndentation #-} {-# LANGUAGE BangPatterns #-} {-# LANGUAGE CPP #-} {-# LANGUAGE ForeignFunctionInterface #-} @@ -45,7 +46,7 @@ main = do Just myCostCentre -> do assertEqual (cc_label myCostCentre) "MyCostCentre" assertEqual (cc_module myCostCentre) "Main" - assertEqual (cc_srcloc myCostCentre) (Just "tso_and_stack_closures.hs:23:48-80") + assertEqual (cc_srcloc myCostCentre) (Just "tso_and_stack_closures.hs:24:48-80") assertEqual (cc_is_caf myCostCentre) False Nothing -> error $ "MyCostCentre not found in:\n" ++ unlines (cc_label <$> linkedCostCentres costCentre) #endif diff --git a/testsuite/tests/annotations/should_fail/T10826.hs b/testsuite/tests/annotations/should_fail/T10826.hs index cddf33ca6fba..1c80713da4be 100644 --- a/testsuite/tests/annotations/should_fail/T10826.hs +++ b/testsuite/tests/annotations/should_fail/T10826.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} module Test (hook) where diff --git a/testsuite/tests/annotations/should_fail/T10826.stderr b/testsuite/tests/annotations/should_fail/T10826.stderr index 465715ad3eaf..15ba942e813f 100644 --- a/testsuite/tests/annotations/should_fail/T10826.stderr +++ b/testsuite/tests/annotations/should_fail/T10826.stderr @@ -1,6 +1,6 @@ -T10826.hs:6:1: error: - Annotations are not compatible with Safe Haskell. - See https://gitlab.haskell.org/ghc/ghc/issues/10826 - In the annotation: - {-# ANN hook (unsafePerformIO (putStrLn "Woops.")) #-} +T10826.hs:7:1: error: + • Annotations are not compatible with Safe Haskell. + See https://gitlab.haskell.org/ghc/ghc/issues/10826 + • In the annotation: + {-# ANN hook (unsafePerformIO (putStrLn "Woops.")) #-} diff --git a/testsuite/tests/backpack/should_compile/T13140.bkp b/testsuite/tests/backpack/should_compile/T13140.bkp index aa04b98c1e41..0125a6400b9b 100644 --- a/testsuite/tests/backpack/should_compile/T13140.bkp +++ b/testsuite/tests/backpack/should_compile/T13140.bkp @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE RoleAnnotations #-} unit p where signature A where diff --git a/testsuite/tests/backpack/should_compile/bkp32.bkp b/testsuite/tests/backpack/should_compile/bkp32.bkp index 92f37a5a0588..c90a323d59a8 100644 --- a/testsuite/tests/backpack/should_compile/bkp32.bkp +++ b/testsuite/tests/backpack/should_compile/bkp32.bkp @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE RoleAnnotations #-} {-# LANGUAGE ScopedTypeVariables #-} unit prelude-sig where diff --git a/testsuite/tests/backpack/should_compile/bkp37.bkp b/testsuite/tests/backpack/should_compile/bkp37.bkp index 7f116dc93dbf..9bd70ff6ec67 100644 --- a/testsuite/tests/backpack/should_compile/bkp37.bkp +++ b/testsuite/tests/backpack/should_compile/bkp37.bkp @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE FlexibleInstances #-} unit p where signature A where diff --git a/testsuite/tests/backpack/should_compile/bkp38.bkp b/testsuite/tests/backpack/should_compile/bkp38.bkp index 952367512cfe..41ea93cf24e0 100644 --- a/testsuite/tests/backpack/should_compile/bkp38.bkp +++ b/testsuite/tests/backpack/should_compile/bkp38.bkp @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE FlexibleInstances #-} {-# LANGUAGE RoleAnnotations #-} unit p where diff --git a/testsuite/tests/backpack/should_compile/bkp39.bkp b/testsuite/tests/backpack/should_compile/bkp39.bkp index a6216edc24ba..4af903856fbf 100644 --- a/testsuite/tests/backpack/should_compile/bkp39.bkp +++ b/testsuite/tests/backpack/should_compile/bkp39.bkp @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE ConstraintKinds #-} unit p where signature A where diff --git a/testsuite/tests/backpack/should_compile/bkp40.bkp b/testsuite/tests/backpack/should_compile/bkp40.bkp index 3f9745668614..d149d758774f 100644 --- a/testsuite/tests/backpack/should_compile/bkp40.bkp +++ b/testsuite/tests/backpack/should_compile/bkp40.bkp @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE ConstraintKinds #-} {-# LANGUAGE TypeSynonymInstances #-} {-# LANGUAGE FlexibleInstances #-} diff --git a/testsuite/tests/backpack/should_compile/bkp48.bkp b/testsuite/tests/backpack/should_compile/bkp48.bkp index d48d0359d2a5..75c8bb6e2f0e 100644 --- a/testsuite/tests/backpack/should_compile/bkp48.bkp +++ b/testsuite/tests/backpack/should_compile/bkp48.bkp @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies #-} unit p where signature A where diff --git a/testsuite/tests/backpack/should_fail/bkpfail17.bkp b/testsuite/tests/backpack/should_fail/bkpfail17.bkp index 847bdfaf58f9..5729d8c6628e 100644 --- a/testsuite/tests/backpack/should_fail/bkpfail17.bkp +++ b/testsuite/tests/backpack/should_fail/bkpfail17.bkp @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE NoImplicitPrelude #-} unit p where signature ShouldFail where diff --git a/testsuite/tests/backpack/should_fail/bkpfail17.stderr b/testsuite/tests/backpack/should_fail/bkpfail17.stderr index 81e47ec52431..2777b503edc3 100644 --- a/testsuite/tests/backpack/should_fail/bkpfail17.stderr +++ b/testsuite/tests/backpack/should_fail/bkpfail17.stderr @@ -2,8 +2,8 @@ [1 of 1] Compiling ShouldFail[sig] ( p/ShouldFail.hsig, nothing ) [2 of 2] Processing q Instantiating q - [1 of 1] Including p[ShouldFail=base-4.13.0.0:Prelude] - Instantiating p[ShouldFail=base-4.13.0.0:Prelude] + [1 of 1] Including p[ShouldFail=base-4.16.0.0:Prelude] + Instantiating p[ShouldFail=base-4.16.0.0:Prelude] [1 of 1] Compiling ShouldFail[sig] ( p/ShouldFail.hsig, bkpfail17.out/p/p-2W6J7O3LvroH97zGxbPEGF/ShouldFail.o ) <no location info>: error: diff --git a/testsuite/tests/backpack/should_fail/bkpfail23.bkp b/testsuite/tests/backpack/should_fail/bkpfail23.bkp index a7e52cef4f44..831ce42c721c 100644 --- a/testsuite/tests/backpack/should_fail/bkpfail23.bkp +++ b/testsuite/tests/backpack/should_fail/bkpfail23.bkp @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE GADTs, RoleAnnotations #-} unit p where signature H where diff --git a/testsuite/tests/backpack/should_fail/bkpfail23.stderr b/testsuite/tests/backpack/should_fail/bkpfail23.stderr index 6a2eb8ce1e5e..a8144dbde5e7 100644 --- a/testsuite/tests/backpack/should_fail/bkpfail23.stderr +++ b/testsuite/tests/backpack/should_fail/bkpfail23.stderr @@ -10,7 +10,7 @@ Instantiating p[H=h:H] [1 of 2] Compiling H[sig] ( p/H.hsig, bkpfail23.out/p/p-6KeuBvYi0jvLWqVbkSAZMq/H.o ) -bkpfail23.bkp:14:9: error: +bkpfail23.bkp:15:9: error: • Type constructor ‘F’ has conflicting definitions in the module and its hsig file Main module: type F :: * -> * diff --git a/testsuite/tests/backpack/should_fail/bkpfail25.bkp b/testsuite/tests/backpack/should_fail/bkpfail25.bkp index 322a70a93ee6..234e9bd13728 100644 --- a/testsuite/tests/backpack/should_fail/bkpfail25.bkp +++ b/testsuite/tests/backpack/should_fail/bkpfail25.bkp @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeSynonymInstances #-} unit p where signature H where diff --git a/testsuite/tests/backpack/should_fail/bkpfail25.stderr b/testsuite/tests/backpack/should_fail/bkpfail25.stderr index cedcd3039958..08cb0711fe41 100644 --- a/testsuite/tests/backpack/should_fail/bkpfail25.stderr +++ b/testsuite/tests/backpack/should_fail/bkpfail25.stderr @@ -2,7 +2,7 @@ [1 of 2] Compiling H[sig] ( p/H.hsig, nothing ) [2 of 2] Compiling M ( p/M.hs, nothing ) -bkpfail25.bkp:7:18: warning: [-Wmissing-methods (in -Wdefault)] +bkpfail25.bkp:8:18: warning: [-Wmissing-methods (in -Wdefault)] • No explicit implementation for ‘fmap’ • In the instance declaration for ‘Functor T’ @@ -15,7 +15,7 @@ bkpfail25.bkp:7:18: warning: [-Wmissing-methods (in -Wdefault)] Instantiating p[H=q:H] [1 of 2] Compiling H[sig] ( p/H.hsig, bkpfail25.out/p/p-D5Mg3foBSCrDbQDKH4WGSG/H.o ) -bkpfail25.bkp:12:9: error: +bkpfail25.bkp:13:9: error: • Type constructor ‘T’ has conflicting definitions in the module and its hsig file Main module: type T :: * -> * diff --git a/testsuite/tests/backpack/should_fail/bkpfail26.bkp b/testsuite/tests/backpack/should_fail/bkpfail26.bkp index 5ea5b6bada53..13592b682fb2 100644 --- a/testsuite/tests/backpack/should_fail/bkpfail26.bkp +++ b/testsuite/tests/backpack/should_fail/bkpfail26.bkp @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeSynonymInstances #-} unit p where signature H where diff --git a/testsuite/tests/backpack/should_fail/bkpfail26.stderr b/testsuite/tests/backpack/should_fail/bkpfail26.stderr index 09410cedfef2..f697f47212da 100644 --- a/testsuite/tests/backpack/should_fail/bkpfail26.stderr +++ b/testsuite/tests/backpack/should_fail/bkpfail26.stderr @@ -10,7 +10,7 @@ Instantiating p[H=q:H] [1 of 2] Compiling H[sig] ( p/H.hsig, bkpfail26.out/p/p-D5Mg3foBSCrDbQDKH4WGSG/H.o ) -bkpfail26.bkp:15:9: error: +bkpfail26.bkp:16:9: error: • Type constructor ‘T’ has conflicting definitions in the module and its hsig file Main module: type T :: * -> * diff --git a/testsuite/tests/backpack/should_fail/bkpfail28.bkp b/testsuite/tests/backpack/should_fail/bkpfail28.bkp index aa3f1a489bbd..5c3ba454f7e1 100644 --- a/testsuite/tests/backpack/should_fail/bkpfail28.bkp +++ b/testsuite/tests/backpack/should_fail/bkpfail28.bkp @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE FlexibleInstances #-} -- This doesn't work: GHC MUST pick the wrong one! -- {-# LANGUAGE IncoherentInstances #-} diff --git a/testsuite/tests/backpack/should_fail/bkpfail28.stderr b/testsuite/tests/backpack/should_fail/bkpfail28.stderr index 4850e19240d6..ef8d72cfe3fe 100644 --- a/testsuite/tests/backpack/should_fail/bkpfail28.stderr +++ b/testsuite/tests/backpack/should_fail/bkpfail28.stderr @@ -6,22 +6,22 @@ [1 of 4] Compiling A[sig] ( r/A.hsig, nothing ) [2 of 4] Compiling R ( r/R.hs, nothing ) -bkpfail28.bkp:18:13: error: +bkpfail28.bkp:19:13: error: • Overlapping instances for Show (K a) arising from a use of ‘show’ Matching instances: instance [safe] Show a => Show (K a) - -- Defined at bkpfail28.bkp:11:18 + -- Defined at bkpfail28.bkp:12:18 instance [safe] Read a => Show (K a) - -- Defined at bkpfail28.bkp:11:18 + -- Defined at bkpfail28.bkp:12:18 • In the expression: show In an equation for ‘f’: f = show -bkpfail28.bkp:20:13: error: +bkpfail28.bkp:21:13: error: • Overlapping instances for Show (K a) arising from a use of ‘show’ Matching instances: instance [safe] Show a => Show (K a) - -- Defined at bkpfail28.bkp:11:18 + -- Defined at bkpfail28.bkp:12:18 instance [safe] Read a => Show (K a) - -- Defined at bkpfail28.bkp:11:18 + -- Defined at bkpfail28.bkp:12:18 • In the expression: show In an equation for ‘g’: g = show diff --git a/testsuite/tests/backpack/should_fail/bkpfail42.bkp b/testsuite/tests/backpack/should_fail/bkpfail42.bkp index 8face3f3be90..dd305e834426 100644 --- a/testsuite/tests/backpack/should_fail/bkpfail42.bkp +++ b/testsuite/tests/backpack/should_fail/bkpfail42.bkp @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies #-} unit p where signature A where diff --git a/testsuite/tests/backpack/should_fail/bkpfail42.stderr b/testsuite/tests/backpack/should_fail/bkpfail42.stderr index aa6857e9a1a4..0dfef9355f0f 100644 --- a/testsuite/tests/backpack/should_fail/bkpfail42.stderr +++ b/testsuite/tests/backpack/should_fail/bkpfail42.stderr @@ -3,7 +3,7 @@ [2 of 2] Processing q [1 of 2] Compiling A[sig] ( q/A.hsig, nothing ) -bkpfail42.bkp:9:9: error: +bkpfail42.bkp:10:9: error: • Type constructor ‘F’ has conflicting definitions in the module and its hsig file Main module: type F :: * -> * diff --git a/testsuite/tests/backpack/should_fail/bkpfail45.bkp b/testsuite/tests/backpack/should_fail/bkpfail45.bkp index f60d45fd6a8d..2222442bb383 100644 --- a/testsuite/tests/backpack/should_fail/bkpfail45.bkp +++ b/testsuite/tests/backpack/should_fail/bkpfail45.bkp @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE RoleAnnotations, FlexibleContexts #-} unit p where signature A where diff --git a/testsuite/tests/backpack/should_fail/bkpfail45.stderr b/testsuite/tests/backpack/should_fail/bkpfail45.stderr index f28f18316b0d..e2b4236aabc6 100644 --- a/testsuite/tests/backpack/should_fail/bkpfail45.stderr +++ b/testsuite/tests/backpack/should_fail/bkpfail45.stderr @@ -10,7 +10,7 @@ Instantiating p[A=a:A] [1 of 2] Compiling A[sig] ( p/A.hsig, bkpfail45.out/p/p-KvF5Y9pEVY39j64PHPNj9i/A.o ) -bkpfail45.bkp:13:9: error: +bkpfail45.bkp:14:9: error: • Type constructor ‘T’ has conflicting definitions in the module and its hsig file Main module: type role T phantom diff --git a/testsuite/tests/backpack/should_fail/bkpfail46.bkp b/testsuite/tests/backpack/should_fail/bkpfail46.bkp index 0fc8b676a843..7c59223d7306 100644 --- a/testsuite/tests/backpack/should_fail/bkpfail46.bkp +++ b/testsuite/tests/backpack/should_fail/bkpfail46.bkp @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE ConstraintKinds #-} unit p where signature A where diff --git a/testsuite/tests/backpack/should_fail/bkpfail46.stderr b/testsuite/tests/backpack/should_fail/bkpfail46.stderr index 908866f67c01..5ab1a5fddb73 100644 --- a/testsuite/tests/backpack/should_fail/bkpfail46.stderr +++ b/testsuite/tests/backpack/should_fail/bkpfail46.stderr @@ -10,7 +10,7 @@ Instantiating p[A=q:A] [1 of 2] Compiling A[sig] ( p/A.hsig, bkpfail46.out/p/p-HVmFlcYSefiK5n1aDP1v7x/A.o ) -bkpfail46.bkp:15:9: error: +bkpfail46.bkp:16:9: error: • Type constructor ‘K’ has conflicting definitions in the module and its hsig file Main module: type K :: * -> Constraint diff --git a/testsuite/tests/backpack/should_fail/bkpfail47.bkp b/testsuite/tests/backpack/should_fail/bkpfail47.bkp index b8d4ae66d883..6d531769abe8 100644 --- a/testsuite/tests/backpack/should_fail/bkpfail47.bkp +++ b/testsuite/tests/backpack/should_fail/bkpfail47.bkp @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE RoleAnnotations #-} unit p where signature A where diff --git a/testsuite/tests/backpack/should_fail/bkpfail47.stderr b/testsuite/tests/backpack/should_fail/bkpfail47.stderr index d7f7c174d6cd..86453f28ea73 100644 --- a/testsuite/tests/backpack/should_fail/bkpfail47.stderr +++ b/testsuite/tests/backpack/should_fail/bkpfail47.stderr @@ -5,7 +5,7 @@ [3 of 3] Processing r [1 of 3] Compiling A[sig] ( r/A.hsig, nothing ) -bkpfail47.bkp:9:9: error: +bkpfail47.bkp:10:9: error: • Type constructor ‘T’ has conflicting definitions in the module and its hsig file Main module: type role T representational nominal diff --git a/testsuite/tests/backpack/should_run/bkprun05.bkp b/testsuite/tests/backpack/should_run/bkprun05.bkp index 6db2daa96358..1413574f36bf 100644 --- a/testsuite/tests/backpack/should_run/bkprun05.bkp +++ b/testsuite/tests/backpack/should_run/bkprun05.bkp @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE RoleAnnotations #-} unit app where signature Map where diff --git a/testsuite/tests/backpack/should_run/bkprun06.bkp b/testsuite/tests/backpack/should_run/bkprun06.bkp index 121c59236bcf..3c2e91ce4106 100644 --- a/testsuite/tests/backpack/should_run/bkprun06.bkp +++ b/testsuite/tests/backpack/should_run/bkprun06.bkp @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE RoleAnnotations #-} unit sigs where signature Map where diff --git a/testsuite/tests/codeGen/should_run/cas_int.hs b/testsuite/tests/codeGen/should_run/cas_int.hs index fc830c4d8a00..f3c0bd013765 100644 --- a/testsuite/tests/codeGen/should_run/cas_int.hs +++ b/testsuite/tests/codeGen/should_run/cas_int.hs @@ -1,5 +1,6 @@ -{-# LANGUAGE CPP, MagicHash, BlockArguments, UnboxedTuples #-} -{-# LANGUAGE CPP, MagicHash, BlockArguments, ScopedTypeVariables #-} +{-# LANGUAGE Haskell2010 #-} +{-# LANGUAGE NondecreasingIndentation #-} +{-# LANGUAGE CPP, MagicHash, BlockArguments, UnboxedTuples, ScopedTypeVariables #-} -- Test the atomic exchange primop. diff --git a/testsuite/tests/deSugar/should_compile/T2431.hs b/testsuite/tests/deSugar/should_compile/T2431.hs index 57c0a1f31204..9c6ecf1ed3f3 100644 --- a/testsuite/tests/deSugar/should_compile/T2431.hs +++ b/testsuite/tests/deSugar/should_compile/T2431.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeOperators, GADTs, EmptyCase #-} module T2431 where diff --git a/testsuite/tests/deSugar/should_run/T18151.hs b/testsuite/tests/deSugar/should_run/T18151.hs index b17c8a9ff046..59279d44be06 100644 --- a/testsuite/tests/deSugar/should_run/T18151.hs +++ b/testsuite/tests/deSugar/should_run/T18151.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} -- According to the Report this should reduce to (). However, in #18151 it was -- reported that GHC bottoms. x :: () diff --git a/testsuite/tests/dependent/should_compile/Dep2.hs b/testsuite/tests/dependent/should_compile/Dep2.hs index 34be3cffc600..adaf5c3f99e1 100644 --- a/testsuite/tests/dependent/should_compile/Dep2.hs +++ b/testsuite/tests/dependent/should_compile/Dep2.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE PolyKinds, GADTs #-} module Dep2 where diff --git a/testsuite/tests/dependent/should_compile/DkNameRes.hs b/testsuite/tests/dependent/should_compile/DkNameRes.hs index 4110b338826b..f871c9cf890d 100644 --- a/testsuite/tests/dependent/should_compile/DkNameRes.hs +++ b/testsuite/tests/dependent/should_compile/DkNameRes.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies, DataKinds, PolyKinds #-} module DkNameRes where diff --git a/testsuite/tests/dependent/should_compile/KindEqualities2.hs b/testsuite/tests/dependent/should_compile/KindEqualities2.hs index d24502bc713a..c798524434fa 100644 --- a/testsuite/tests/dependent/should_compile/KindEqualities2.hs +++ b/testsuite/tests/dependent/should_compile/KindEqualities2.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE DataKinds, GADTs, PolyKinds, TypeFamilies, ExplicitForAll, TemplateHaskell, UndecidableInstances, ScopedTypeVariables #-} diff --git a/testsuite/tests/dependent/should_compile/RaeBlogPost.hs b/testsuite/tests/dependent/should_compile/RaeBlogPost.hs index b048a49e44d0..d0961dd3845a 100644 --- a/testsuite/tests/dependent/should_compile/RaeBlogPost.hs +++ b/testsuite/tests/dependent/should_compile/RaeBlogPost.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE DataKinds, PolyKinds, GADTs, TypeOperators, TypeFamilies #-} {-# OPTIONS_GHC -fwarn-unticked-promoted-constructors #-} diff --git a/testsuite/tests/dependent/should_compile/RaeJobTalk.hs b/testsuite/tests/dependent/should_compile/RaeJobTalk.hs index 90a72c2a9af1..21d68c2a2b1c 100644 --- a/testsuite/tests/dependent/should_compile/RaeJobTalk.hs +++ b/testsuite/tests/dependent/should_compile/RaeJobTalk.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {- Copyright (c) 2016 Richard Eisenberg -} diff --git a/testsuite/tests/dependent/should_compile/T11711.hs b/testsuite/tests/dependent/should_compile/T11711.hs index 814b2a4a68dd..bcbb7cec8303 100644 --- a/testsuite/tests/dependent/should_compile/T11711.hs +++ b/testsuite/tests/dependent/should_compile/T11711.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE PatternSynonyms #-} {-# LANGUAGE GADTs #-} {-# LANGUAGE RankNTypes #-} diff --git a/testsuite/tests/dependent/should_compile/T12442.hs b/testsuite/tests/dependent/should_compile/T12442.hs index b4bcdb9d62bd..fa0096b4e424 100644 --- a/testsuite/tests/dependent/should_compile/T12442.hs +++ b/testsuite/tests/dependent/should_compile/T12442.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} -- Based on https://github.com/idris-lang/Idris-dev/blob/v0.9.10/libs/effects/Effects.idr {-# LANGUAGE DataKinds, PolyKinds, ScopedTypeVariables, TypeOperators, diff --git a/testsuite/tests/dependent/should_compile/T14066a.hs b/testsuite/tests/dependent/should_compile/T14066a.hs index 1d6b72491ecb..23574a202901 100644 --- a/testsuite/tests/dependent/should_compile/T14066a.hs +++ b/testsuite/tests/dependent/should_compile/T14066a.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies, DataKinds, PolyKinds, ExplicitForAll, GADTs, UndecidableInstances, RankNTypes, ScopedTypeVariables #-} diff --git a/testsuite/tests/dependent/should_compile/T14066a.stderr b/testsuite/tests/dependent/should_compile/T14066a.stderr index e3ee00fceaf1..889d51b1cffd 100644 --- a/testsuite/tests/dependent/should_compile/T14066a.stderr +++ b/testsuite/tests/dependent/should_compile/T14066a.stderr @@ -1,5 +1,5 @@ -T14066a.hs:13:3: warning: +T14066a.hs:14:3: warning: Type family instance equation is overlapped: forall {c} {d} {x :: c} {y :: d}. - Bar x y = Bool -- Defined at T14066a.hs:13:3 + Bar x y = Bool -- Defined at T14066a.hs:14:3 diff --git a/testsuite/tests/dependent/should_compile/T14556.hs b/testsuite/tests/dependent/should_compile/T14556.hs index 133a9e6a4492..dd51b05726fe 100644 --- a/testsuite/tests/dependent/should_compile/T14556.hs +++ b/testsuite/tests/dependent/should_compile/T14556.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# Language UndecidableInstances, DataKinds, TypeOperators, PolyKinds, TypeFamilies, GADTs, LambdaCase, ScopedTypeVariables #-} diff --git a/testsuite/tests/dependent/should_compile/T14749.hs b/testsuite/tests/dependent/should_compile/T14749.hs index bf3d5c488a93..5e9bfb0ea4ae 100644 --- a/testsuite/tests/dependent/should_compile/T14749.hs +++ b/testsuite/tests/dependent/should_compile/T14749.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE GADTs, TypeOperators, DataKinds, TypeFamilies, PolyKinds, TypeFamilyDependencies #-} module T14749 where diff --git a/testsuite/tests/dependent/should_compile/T16326_Compile1.hs b/testsuite/tests/dependent/should_compile/T16326_Compile1.hs index 138ab486ca81..857716d489fb 100644 --- a/testsuite/tests/dependent/should_compile/T16326_Compile1.hs +++ b/testsuite/tests/dependent/should_compile/T16326_Compile1.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE DataKinds #-} {-# LANGUAGE GADTs #-} {-# LANGUAGE PolyKinds #-} diff --git a/testsuite/tests/dependent/should_compile/TypeLevelVec.hs b/testsuite/tests/dependent/should_compile/TypeLevelVec.hs index 0e2f0c774405..9f67efa64482 100644 --- a/testsuite/tests/dependent/should_compile/TypeLevelVec.hs +++ b/testsuite/tests/dependent/should_compile/TypeLevelVec.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE DataKinds, PolyKinds, UnicodeSyntax, GADTs, NoImplicitPrelude, TypeOperators, TypeFamilies #-} {-# OPTIONS_GHC -fno-warn-unticked-promoted-constructors #-} diff --git a/testsuite/tests/dependent/should_compile/dynamic-paper.hs b/testsuite/tests/dependent/should_compile/dynamic-paper.hs index 6fae39f5a14a..eaba011625b6 100644 --- a/testsuite/tests/dependent/should_compile/dynamic-paper.hs +++ b/testsuite/tests/dependent/should_compile/dynamic-paper.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {- This is the code extracted from "A reflection on types", by Simon PJ, Stephanie Weirich, Richard Eisenberg, and Dimitrios Vytiniotis, 2016. -} diff --git a/testsuite/tests/dependent/should_compile/mkGADTVars.hs b/testsuite/tests/dependent/should_compile/mkGADTVars.hs index 13ac0248bfde..13a647b9ce9f 100644 --- a/testsuite/tests/dependent/should_compile/mkGADTVars.hs +++ b/testsuite/tests/dependent/should_compile/mkGADTVars.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE GADTs, PolyKinds, RankNTypes #-} module GADTVars where diff --git a/testsuite/tests/dependent/should_fail/T13601.hs b/testsuite/tests/dependent/should_fail/T13601.hs index a8fa34d4a0b7..7667201add18 100644 --- a/testsuite/tests/dependent/should_fail/T13601.hs +++ b/testsuite/tests/dependent/should_fail/T13601.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies, DataKinds, PolyKinds #-} import GHC.Exts diff --git a/testsuite/tests/dependent/should_fail/T13601.stderr b/testsuite/tests/dependent/should_fail/T13601.stderr index bc2877c3e6e8..269dd00b2029 100644 --- a/testsuite/tests/dependent/should_fail/T13601.stderr +++ b/testsuite/tests/dependent/should_fail/T13601.stderr @@ -1,5 +1,5 @@ -T13601.hs:18:16: error: +T13601.hs:19:16: error: • Expected a type, but ‘Logic a’ has kind ‘TYPE (Rep rep)’ • In the first argument of ‘Boolean’, namely ‘(Logic a)’ In the class declaration for ‘Eq’ diff --git a/testsuite/tests/dependent/should_fail/T13780c.hs b/testsuite/tests/dependent/should_fail/T13780c.hs index 78e09f5ef11b..c26f9ddbe997 100644 --- a/testsuite/tests/dependent/should_fail/T13780c.hs +++ b/testsuite/tests/dependent/should_fail/T13780c.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE GADTs #-} {-# LANGUAGE TypeFamilies #-} {-# LANGUAGE DataKinds, PolyKinds #-} diff --git a/testsuite/tests/dependent/should_fail/T13780c.stderr b/testsuite/tests/dependent/should_fail/T13780c.stderr index 9a196f4bd729..2cdb59ad1e16 100644 --- a/testsuite/tests/dependent/should_fail/T13780c.stderr +++ b/testsuite/tests/dependent/should_fail/T13780c.stderr @@ -1,13 +1,13 @@ [1 of 2] Compiling T13780b ( T13780b.hs, T13780b.o ) [2 of 2] Compiling T13780c ( T13780c.hs, T13780c.o ) -T13780c.hs:11:16: error: +T13780c.hs:12:16: error: • Data constructor ‘SFalse’ cannot be used here (it comes from a data family instance) • In the third argument of ‘ElimBool’, namely ‘SFalse’ In the type family declaration for ‘ElimBool’ -T13780c.hs:12:16: error: +T13780c.hs:13:16: error: • Data constructor ‘STrue’ cannot be used here (it comes from a data family instance) • In the third argument of ‘ElimBool’, namely ‘STrue’ diff --git a/testsuite/tests/dependent/should_fail/T15215.hs b/testsuite/tests/dependent/should_fail/T15215.hs index e4968a1654c2..98b5e841b8e7 100644 --- a/testsuite/tests/dependent/should_fail/T15215.hs +++ b/testsuite/tests/dependent/should_fail/T15215.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE GADTs #-} {-# LANGUAGE ScopedTypeVariables #-} {-# LANGUAGE TypeInType #-} diff --git a/testsuite/tests/dependent/should_fail/T15215.stderr b/testsuite/tests/dependent/should_fail/T15215.stderr index be2d7c75e7de..d852dedc6de1 100644 --- a/testsuite/tests/dependent/should_fail/T15215.stderr +++ b/testsuite/tests/dependent/should_fail/T15215.stderr @@ -1,11 +1,11 @@ -T15215.hs:9:3: error: +T15215.hs:10:3: error: • Non type-variable argument in the constraint: Show (Maybe a) (Use FlexibleContexts to permit this) • In the definition of data constructor ‘MkA’ In the data type declaration for ‘A’ -T15215.hs:16:14: error: +T15215.hs:17:14: error: • Data constructor ‘MkB’ cannot be used here (it has an unpromotable context ‘Show a’) • In the first argument of ‘SA’, namely ‘MkB’ diff --git a/testsuite/tests/dependent/should_fail/T15380.hs b/testsuite/tests/dependent/should_fail/T15380.hs index 32ea8ec7249f..a0e8abc81940 100644 --- a/testsuite/tests/dependent/should_fail/T15380.hs +++ b/testsuite/tests/dependent/should_fail/T15380.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies #-} {-# LANGUAGE TypeInType #-} {-# LANGUAGE TypeOperators #-} diff --git a/testsuite/tests/dependent/should_fail/T15380.stderr b/testsuite/tests/dependent/should_fail/T15380.stderr index 9b30078c64d4..405d572c731c 100644 --- a/testsuite/tests/dependent/should_fail/T15380.stderr +++ b/testsuite/tests/dependent/should_fail/T15380.stderr @@ -1,5 +1,5 @@ -T15380.hs:16:16: error: +T15380.hs:17:16: error: • Expecting one more argument to ‘To (M x)’ Expected a type, but ‘To (M x)’ has kind ‘Rep (M x) -> M x’ • In the type ‘To (M x)’ diff --git a/testsuite/tests/dependent/should_fail/T16326_Fail7.hs b/testsuite/tests/dependent/should_fail/T16326_Fail7.hs index 9c3801faf03f..a7999ca06925 100644 --- a/testsuite/tests/dependent/should_fail/T16326_Fail7.hs +++ b/testsuite/tests/dependent/should_fail/T16326_Fail7.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE PolyKinds #-} module T16326_Fail7 where diff --git a/testsuite/tests/dependent/should_fail/T16326_Fail7.stderr b/testsuite/tests/dependent/should_fail/T16326_Fail7.stderr index 13fc416995d3..c5aba0b06d5a 100644 --- a/testsuite/tests/dependent/should_fail/T16326_Fail7.stderr +++ b/testsuite/tests/dependent/should_fail/T16326_Fail7.stderr @@ -1,5 +1,5 @@ -T16326_Fail7.hs:8:13: error: +T16326_Fail7.hs:9:13: error: Illegal symbol ‘forall’ in type Perhaps you intended to use RankNTypes or a similar language extension to enable explicit-forall syntax: forall <tvs>. <type> diff --git a/testsuite/tests/deriving/should_compile/T12144_2.hs b/testsuite/tests/deriving/should_compile/T12144_2.hs index dc9f64e90ebb..d3e5f771dbc1 100644 --- a/testsuite/tests/deriving/should_compile/T12144_2.hs +++ b/testsuite/tests/deriving/should_compile/T12144_2.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE DeriveAnyClass #-} module T12144_2 where diff --git a/testsuite/tests/deriving/should_compile/T14578.hs b/testsuite/tests/deriving/should_compile/T14578.hs index d0700ea9b0fc..231796cda9fb 100644 --- a/testsuite/tests/deriving/should_compile/T14578.hs +++ b/testsuite/tests/deriving/should_compile/T14578.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE GeneralizedNewtypeDeriving #-} module T14578 where diff --git a/testsuite/tests/deriving/should_compile/T14579.hs b/testsuite/tests/deriving/should_compile/T14579.hs index 518dffe2144f..9addb5bc5344 100644 --- a/testsuite/tests/deriving/should_compile/T14579.hs +++ b/testsuite/tests/deriving/should_compile/T14579.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE GeneralizedNewtypeDeriving #-} {-# LANGUAGE DataKinds #-} {-# LANGUAGE PolyKinds #-} diff --git a/testsuite/tests/deriving/should_compile/T14933.hs b/testsuite/tests/deriving/should_compile/T14933.hs index de8562d189a4..5ab808365fbc 100644 --- a/testsuite/tests/deriving/should_compile/T14933.hs +++ b/testsuite/tests/deriving/should_compile/T14933.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE DefaultSignatures #-} {-# LANGUAGE DeriveAnyClass #-} {-# LANGUAGE TypeFamilies #-} diff --git a/testsuite/tests/deriving/should_compile/T17339.hs b/testsuite/tests/deriving/should_compile/T17339.hs index 4312d2ffc4d6..a46e4c793d1d 100644 --- a/testsuite/tests/deriving/should_compile/T17339.hs +++ b/testsuite/tests/deriving/should_compile/T17339.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE DeriveAnyClass #-} {-# LANGUAGE DerivingStrategies #-} {-# LANGUAGE MultiParamTypeClasses #-} diff --git a/testsuite/tests/deriving/should_compile/deriving-1935.hs b/testsuite/tests/deriving/should_compile/deriving-1935.hs index d33b21af134a..af62a747d471 100644 --- a/testsuite/tests/deriving/should_compile/deriving-1935.hs +++ b/testsuite/tests/deriving/should_compile/deriving-1935.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# OPTIONS_GHC -XDeriveDataTypeable #-} -- #1935 diff --git a/testsuite/tests/deriving/should_compile/deriving-1935.stderr b/testsuite/tests/deriving/should_compile/deriving-1935.stderr index 091990bcd9dc..3864e8e2f0d4 100644 --- a/testsuite/tests/deriving/should_compile/deriving-1935.stderr +++ b/testsuite/tests/deriving/should_compile/deriving-1935.stderr @@ -1,15 +1,15 @@ -deriving-1935.hs:17:11: warning: [-Wmissing-methods (in -Wdefault)] +deriving-1935.hs:18:11: warning: [-Wmissing-methods (in -Wdefault)] • No explicit implementation for either ‘==’ or ‘/=’ • In the instance declaration for ‘Eq (T a)’ -deriving-1935.hs:20:11: warning: [-Wmissing-methods (in -Wdefault)] +deriving-1935.hs:21:11: warning: [-Wmissing-methods (in -Wdefault)] • No explicit implementation for either ‘==’ or ‘/=’ • In the instance declaration for ‘Eq (S a)’ -deriving-1935.hs:21:11: warning: [-Wmissing-methods (in -Wdefault)] +deriving-1935.hs:22:11: warning: [-Wmissing-methods (in -Wdefault)] • No explicit implementation for either ‘compare’ or ‘<=’ • In the instance declaration for ‘Ord (S a)’ diff --git a/testsuite/tests/deriving/should_compile/drv-empty-data.hs b/testsuite/tests/deriving/should_compile/drv-empty-data.hs index 383ce8f9f78e..0383b29dbbb2 100644 --- a/testsuite/tests/deriving/should_compile/drv-empty-data.hs +++ b/testsuite/tests/deriving/should_compile/drv-empty-data.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE RoleAnnotations #-} {-# LANGUAGE DeriveTraversable, DeriveGeneric, EmptyCase, DeriveDataTypeable, StandaloneDeriving, DeriveLift #-} diff --git a/testsuite/tests/deriving/should_compile/drv-foldable-traversable1.hs b/testsuite/tests/deriving/should_compile/drv-foldable-traversable1.hs index 712f14a3b50c..52e845798ab4 100644 --- a/testsuite/tests/deriving/should_compile/drv-foldable-traversable1.hs +++ b/testsuite/tests/deriving/should_compile/drv-foldable-traversable1.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE DeriveFunctor, DeriveFoldable, DeriveTraversable #-} {-# LANGUAGE RankNTypes #-} {-# LANGUAGE FlexibleContexts, DatatypeContexts #-} diff --git a/testsuite/tests/deriving/should_compile/drv-foldable-traversable1.stderr b/testsuite/tests/deriving/should_compile/drv-foldable-traversable1.stderr index ceae10cabd63..e8dc7162c268 100644 --- a/testsuite/tests/deriving/should_compile/drv-foldable-traversable1.stderr +++ b/testsuite/tests/deriving/should_compile/drv-foldable-traversable1.stderr @@ -1,3 +1,3 @@ -drv-foldable-traversable1.hs:3:32: - Warning: -XDatatypeContexts is deprecated: It was widely considered a misfeature, and has been removed from the Haskell language. +drv-foldable-traversable1.hs:4:32: warning: + -XDatatypeContexts is deprecated: It was widely considered a misfeature, and has been removed from the Haskell language. diff --git a/testsuite/tests/deriving/should_compile/drv-functor1.hs b/testsuite/tests/deriving/should_compile/drv-functor1.hs index 040d531341ef..2a09ab0b0e8d 100644 --- a/testsuite/tests/deriving/should_compile/drv-functor1.hs +++ b/testsuite/tests/deriving/should_compile/drv-functor1.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE DeriveFunctor #-} {-# LANGUAGE ExistentialQuantification #-} {-# LANGUAGE RankNTypes #-} diff --git a/testsuite/tests/deriving/should_compile/drv-functor1.stderr b/testsuite/tests/deriving/should_compile/drv-functor1.stderr index a531dc56efcc..5592b7d14181 100644 --- a/testsuite/tests/deriving/should_compile/drv-functor1.stderr +++ b/testsuite/tests/deriving/should_compile/drv-functor1.stderr @@ -1,3 +1,3 @@ -drv-functor1.hs:5:14: - Warning: -XDatatypeContexts is deprecated: It was widely considered a misfeature, and has been removed from the Haskell language. +drv-functor1.hs:6:14: warning: + -XDatatypeContexts is deprecated: It was widely considered a misfeature, and has been removed from the Haskell language. diff --git a/testsuite/tests/deriving/should_fail/T10598_fail2.hs b/testsuite/tests/deriving/should_fail/T10598_fail2.hs index ba77fe0fbf96..7bffcf0c6411 100644 --- a/testsuite/tests/deriving/should_fail/T10598_fail2.hs +++ b/testsuite/tests/deriving/should_fail/T10598_fail2.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE DerivingStrategies #-} module T10598_fail2 where diff --git a/testsuite/tests/deriving/should_fail/T10598_fail2.stderr b/testsuite/tests/deriving/should_fail/T10598_fail2.stderr index 5ddd81dd1eda..227be95c02c4 100644 --- a/testsuite/tests/deriving/should_fail/T10598_fail2.stderr +++ b/testsuite/tests/deriving/should_fail/T10598_fail2.stderr @@ -1,11 +1,11 @@ -T10598_fail2.hs:4:37: error: +T10598_fail2.hs:5:37: error: • Can't make a derived instance of ‘Eq A’ with the anyclass strategy: Try enabling DeriveAnyClass • In the data declaration for ‘A’ -T10598_fail2.hs:5:37: error: +T10598_fail2.hs:6:37: error: • Can't make a derived instance of ‘Eq B’ with the newtype strategy: Try GeneralizedNewtypeDeriving for GHC's newtype-deriving extension diff --git a/testsuite/tests/deriving/should_fail/T10598_fail3.hs b/testsuite/tests/deriving/should_fail/T10598_fail3.hs index 23f9ad987f20..11e3e67e76e6 100644 --- a/testsuite/tests/deriving/should_fail/T10598_fail3.hs +++ b/testsuite/tests/deriving/should_fail/T10598_fail3.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE DeriveAnyClass #-} {-# LANGUAGE DerivingStrategies #-} {-# LANGUAGE Safe #-} diff --git a/testsuite/tests/deriving/should_fail/T10598_fail3.stderr b/testsuite/tests/deriving/should_fail/T10598_fail3.stderr index c3f4e123b7b6..1ebc9c9c93ac 100644 --- a/testsuite/tests/deriving/should_fail/T10598_fail3.stderr +++ b/testsuite/tests/deriving/should_fail/T10598_fail3.stderr @@ -1,4 +1,4 @@ -T10598_fail3.hs:8:36: error: +T10598_fail3.hs:9:36: error: • Generic instances can only be derived in Safe Haskell using the stock strategy. • In the instance declaration for ‘Generic T’ diff --git a/testsuite/tests/deriving/should_fail/T10598_fail6.hs b/testsuite/tests/deriving/should_fail/T10598_fail6.hs index 673bfcc97136..8ed5cdd26224 100644 --- a/testsuite/tests/deriving/should_fail/T10598_fail6.hs +++ b/testsuite/tests/deriving/should_fail/T10598_fail6.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE DeriveAnyClass #-} {-# LANGUAGE GeneralizedNewtypeDeriving #-} module T10598_fail6 where diff --git a/testsuite/tests/deriving/should_fail/T10598_fail6.stderr b/testsuite/tests/deriving/should_fail/T10598_fail6.stderr index a80e5bab5632..0de1fe50bffa 100644 --- a/testsuite/tests/deriving/should_fail/T10598_fail6.stderr +++ b/testsuite/tests/deriving/should_fail/T10598_fail6.stderr @@ -1,5 +1,5 @@ -T10598_fail6.hs:5:41: error: +T10598_fail6.hs:6:41: error: • Can't make a derived instance of ‘Functor F’ (even with cunning GeneralizedNewtypeDeriving): You need DeriveFunctor to derive an instance for this class diff --git a/testsuite/tests/deriving/should_fail/T10684.hs b/testsuite/tests/deriving/should_fail/T10684.hs index fdda0c7e46aa..ae532a15bf5c 100644 --- a/testsuite/tests/deriving/should_fail/T10684.hs +++ b/testsuite/tests/deriving/should_fail/T10684.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module A where import GHC.Generics data A = A deriving (Show, Generic) diff --git a/testsuite/tests/deriving/should_fail/T10684.stderr b/testsuite/tests/deriving/should_fail/T10684.stderr index 6cdbac230107..0724f8ec847f 100644 --- a/testsuite/tests/deriving/should_fail/T10684.stderr +++ b/testsuite/tests/deriving/should_fail/T10684.stderr @@ -1,5 +1,5 @@ -T10684.hs:3:28: error: +T10684.hs:4:28: error: • Can't make a derived instance of ‘Generic A’: You need DeriveGeneric to derive an instance for this class • In the data declaration for ‘A’ diff --git a/testsuite/tests/deriving/should_fail/T1133A.hs b/testsuite/tests/deriving/should_fail/T1133A.hs index 2c8421aaf1fe..743772dd1423 100644 --- a/testsuite/tests/deriving/should_fail/T1133A.hs +++ b/testsuite/tests/deriving/should_fail/T1133A.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module T1133A where diff --git a/testsuite/tests/deriving/should_fail/T1133A.stderr b/testsuite/tests/deriving/should_fail/T1133A.stderr index 23b93409dafb..1c8f686f2a37 100644 --- a/testsuite/tests/deriving/should_fail/T1133A.stderr +++ b/testsuite/tests/deriving/should_fail/T1133A.stderr @@ -1,7 +1,7 @@ -T1133A.hs:6:28: - Can't make a derived instance of ‘Enum X’: - ‘X’ must be an enumeration type - (an enumeration consists of one or more nullary, non-GADT constructors) - Try GeneralizedNewtypeDeriving for GHC's newtype-deriving extension - In the newtype declaration for ‘X’ +T1133A.hs:7:28: error: + • Can't make a derived instance of ‘Enum X’: + ‘X’ must be an enumeration type + (an enumeration consists of one or more nullary, non-GADT constructors) + Try GeneralizedNewtypeDeriving for GHC's newtype-deriving extension + • In the newtype declaration for ‘X’ diff --git a/testsuite/tests/deriving/should_fail/T12801.hs b/testsuite/tests/deriving/should_fail/T12801.hs index 22bbdf0aae34..6bb773a22d67 100644 --- a/testsuite/tests/deriving/should_fail/T12801.hs +++ b/testsuite/tests/deriving/should_fail/T12801.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} data Container = Container [Wibble Int] deriving (Eq, Show) diff --git a/testsuite/tests/deriving/should_fail/T12801.stderr b/testsuite/tests/deriving/should_fail/T12801.stderr index 7bc63df715de..cd3193aabe8e 100644 --- a/testsuite/tests/deriving/should_fail/T12801.stderr +++ b/testsuite/tests/deriving/should_fail/T12801.stderr @@ -1,5 +1,5 @@ -T12801.hs:8:17: error: +T12801.hs:9:17: error: • Can't make a derived instance of ‘Functor Wibble’: You need DeriveFunctor to derive an instance for this class • In the data declaration for ‘Wibble’ diff --git a/testsuite/tests/deriving/should_fail/T16181.hs b/testsuite/tests/deriving/should_fail/T16181.hs index 29692dd1a173..b54991c1535b 100644 --- a/testsuite/tests/deriving/should_fail/T16181.hs +++ b/testsuite/tests/deriving/should_fail/T16181.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE DerivingVia #-} {-# LANGUAGE KindSignatures #-} module T16181 where diff --git a/testsuite/tests/deriving/should_fail/T16181.stderr b/testsuite/tests/deriving/should_fail/T16181.stderr index cbac319a2cf6..ed08f53bb2f2 100644 --- a/testsuite/tests/deriving/should_fail/T16181.stderr +++ b/testsuite/tests/deriving/should_fail/T16181.stderr @@ -1,19 +1,19 @@ -T16181.hs:13:13: error: +T16181.hs:14:13: error: • Cannot eta-reduce to an instance of form instance (...) => Show1 (FlipConst a) • In the newtype declaration for ‘FlipConst’ -T16181.hs:13:20: error: +T16181.hs:14:20: error: • Cannot eta-reduce to an instance of form instance (...) => Eq1 (FlipConst a) • In the newtype declaration for ‘FlipConst’ -T16181.hs:18:14: error: +T16181.hs:19:14: error: • Cannot eta-reduce to an instance of form instance (...) => MonadTrans (Q x) • In the newtype declaration for ‘Q’ -T16181.hs:25:12: error: +T16181.hs:26:12: error: • Cannot eta-reduce to an instance of form instance (...) => C T • In the data declaration for ‘T’ diff --git a/testsuite/tests/deriving/should_fail/T1830_1.hs b/testsuite/tests/deriving/should_fail/T1830_1.hs index e3c2889c1c55..a3ddece39030 100644 --- a/testsuite/tests/deriving/should_fail/T1830_1.hs +++ b/testsuite/tests/deriving/should_fail/T1830_1.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module T1830_1 where import Language.Haskell.TH.Syntax (Lift) diff --git a/testsuite/tests/deriving/should_fail/T1830_1.stderr b/testsuite/tests/deriving/should_fail/T1830_1.stderr index c869b0cd1672..f4e541771039 100644 --- a/testsuite/tests/deriving/should_fail/T1830_1.stderr +++ b/testsuite/tests/deriving/should_fail/T1830_1.stderr @@ -1,5 +1,5 @@ -T1830_1.hs:5:29: error: - Can't make a derived instance of ‘Lift (Foo a)’: - You need DeriveLift to derive an instance for this class - In the data declaration for ‘Foo’ +T1830_1.hs:6:29: error: + • Can't make a derived instance of ‘Lift (Foo a)’: + You need DeriveLift to derive an instance for this class + • In the data declaration for ‘Foo’ diff --git a/testsuite/tests/deriving/should_fail/T3833.hs b/testsuite/tests/deriving/should_fail/T3833.hs index d1196c4112d1..eecb9e789ebd 100644 --- a/testsuite/tests/deriving/should_fail/T3833.hs +++ b/testsuite/tests/deriving/should_fail/T3833.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE StandaloneDeriving #-} -- {-# LANGUAGE GeneralizedNewtypeDeriving #-} diff --git a/testsuite/tests/deriving/should_fail/T3833.stderr b/testsuite/tests/deriving/should_fail/T3833.stderr index bf9a59cb8afe..001fdc4c641f 100644 --- a/testsuite/tests/deriving/should_fail/T3833.stderr +++ b/testsuite/tests/deriving/should_fail/T3833.stderr @@ -1,6 +1,6 @@ -T3833.hs:9:1: error: - Can't make a derived instance of ‘Monoid (DecodeMap e)’: - ‘Monoid’ is not a stock derivable class (Eq, Show, etc.) - Try GeneralizedNewtypeDeriving for GHC's newtype-deriving extension - In the stand-alone deriving instance for ‘Monoid (DecodeMap e)’ +T3833.hs:10:1: error: + • Can't make a derived instance of ‘Monoid (DecodeMap e)’: + ‘Monoid’ is not a stock derivable class (Eq, Show, etc.) + Try GeneralizedNewtypeDeriving for GHC's newtype-deriving extension + • In the stand-alone deriving instance for ‘Monoid (DecodeMap e)’ diff --git a/testsuite/tests/deriving/should_fail/T3834.hs b/testsuite/tests/deriving/should_fail/T3834.hs index 614170198ecc..fa6df580e89d 100644 --- a/testsuite/tests/deriving/should_fail/T3834.hs +++ b/testsuite/tests/deriving/should_fail/T3834.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE StandaloneDeriving #-} diff --git a/testsuite/tests/deriving/should_fail/T3834.stderr b/testsuite/tests/deriving/should_fail/T3834.stderr index 9d2223e1f810..23a605f6143f 100644 --- a/testsuite/tests/deriving/should_fail/T3834.stderr +++ b/testsuite/tests/deriving/should_fail/T3834.stderr @@ -1,6 +1,6 @@ -T3834.hs:8:1: error: - Can't make a derived instance of ‘C T’: - ‘C’ is not a stock derivable class (Eq, Show, etc.) - Try GeneralizedNewtypeDeriving for GHC's newtype-deriving extension - In the stand-alone deriving instance for ‘C T’ +T3834.hs:9:1: error: + • Can't make a derived instance of ‘C T’: + ‘C’ is not a stock derivable class (Eq, Show, etc.) + Try GeneralizedNewtypeDeriving for GHC's newtype-deriving extension + • In the stand-alone deriving instance for ‘C T’ diff --git a/testsuite/tests/deriving/should_fail/T5287.hs b/testsuite/tests/deriving/should_fail/T5287.hs index 6495b62be982..3af467c2cf49 100644 --- a/testsuite/tests/deriving/should_fail/T5287.hs +++ b/testsuite/tests/deriving/should_fail/T5287.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE MultiParamTypeClasses, UndecidableInstances #-} module Bug where class A a oops diff --git a/testsuite/tests/deriving/should_fail/T5287.stderr b/testsuite/tests/deriving/should_fail/T5287.stderr index 20ad31dec3e5..479f1f84b50d 100644 --- a/testsuite/tests/deriving/should_fail/T5287.stderr +++ b/testsuite/tests/deriving/should_fail/T5287.stderr @@ -1,10 +1,10 @@ -T5287.hs:6:10: error: +T5287.hs:7:10: error: • Could not deduce (A a oops0) from the context: A a oops bound by an instance declaration: forall a oops. A a oops => Read (D a) - at T5287.hs:6:10-31 + at T5287.hs:7:10-31 The type variable ‘oops0’ is ambiguous • In the ambiguity check for an instance declaration To defer the ambiguity check to use sites, enable AllowAmbiguousTypes diff --git a/testsuite/tests/deriving/should_fail/T7401_fail.hs b/testsuite/tests/deriving/should_fail/T7401_fail.hs index 730223f17972..29ae0ae6db6e 100644 --- a/testsuite/tests/deriving/should_fail/T7401_fail.hs +++ b/testsuite/tests/deriving/should_fail/T7401_fail.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module T7401_fail where data D deriving Eq diff --git a/testsuite/tests/deriving/should_fail/T7401_fail.stderr b/testsuite/tests/deriving/should_fail/T7401_fail.stderr index feb841f962c9..7f26d3b9e4e7 100644 --- a/testsuite/tests/deriving/should_fail/T7401_fail.stderr +++ b/testsuite/tests/deriving/should_fail/T7401_fail.stderr @@ -1,5 +1,5 @@ -T7401_fail.hs:3:17: error: +T7401_fail.hs:4:17: error: • Can't make a derived instance of ‘Eq D’: ‘D’ must have at least one data constructor Use EmptyDataDeriving to enable deriving for empty data types diff --git a/testsuite/tests/deriving/should_fail/T8851.hs b/testsuite/tests/deriving/should_fail/T8851.hs index 8b5c0e579db4..9015d2be352f 100644 --- a/testsuite/tests/deriving/should_fail/T8851.hs +++ b/testsuite/tests/deriving/should_fail/T8851.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE GeneralizedNewtypeDeriving, ConstrainedClassMethods #-} module T8851 where diff --git a/testsuite/tests/deriving/should_fail/T8851.stderr b/testsuite/tests/deriving/should_fail/T8851.stderr index dd4a6147851d..c4bfff355944 100644 --- a/testsuite/tests/deriving/should_fail/T8851.stderr +++ b/testsuite/tests/deriving/should_fail/T8851.stderr @@ -1,11 +1,11 @@ -T8851.hs:24:12: error: - Couldn't match type ‘Parser’ with ‘MyParser’ - arising from the coercion of the method ‘notFollowedBy’ - from type ‘forall a. - (Monad Parser, Show a) => - Parser a -> Parser ()’ - to type ‘forall a. - (Monad MyParser, Show a) => - MyParser a -> MyParser ()’ - When deriving the instance for (Parsing MyParser) +T8851.hs:25:12: error: + • Couldn't match type ‘Parser’ with ‘MyParser’ + arising from the coercion of the method ‘notFollowedBy’ + from type ‘forall a. + (Monad Parser, Show a) => + Parser a -> Parser ()’ + to type ‘forall a. + (Monad MyParser, Show a) => + MyParser a -> MyParser ()’ + • When deriving the instance for (Parsing MyParser) diff --git a/testsuite/tests/deriving/should_fail/T9600.hs b/testsuite/tests/deriving/should_fail/T9600.hs index a6663ce8c8b3..0547e9dbeed0 100644 --- a/testsuite/tests/deriving/should_fail/T9600.hs +++ b/testsuite/tests/deriving/should_fail/T9600.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} import Control.Applicative newtype Foo a = Foo (a -> a) deriving Applicative diff --git a/testsuite/tests/deriving/should_fail/T9600.stderr b/testsuite/tests/deriving/should_fail/T9600.stderr index 5c03f2efc22b..734e3af9976f 100644 --- a/testsuite/tests/deriving/should_fail/T9600.stderr +++ b/testsuite/tests/deriving/should_fail/T9600.stderr @@ -1,6 +1,6 @@ -T9600.hs:3:39: error: - Can't make a derived instance of ‘Applicative Foo’: - ‘Applicative’ is not a stock derivable class (Eq, Show, etc.) - Try GeneralizedNewtypeDeriving for GHC's newtype-deriving extension - In the newtype declaration for ‘Foo’ +T9600.hs:4:39: error: + • Can't make a derived instance of ‘Applicative Foo’: + ‘Applicative’ is not a stock derivable class (Eq, Show, etc.) + Try GeneralizedNewtypeDeriving for GHC's newtype-deriving extension + • In the newtype declaration for ‘Foo’ diff --git a/testsuite/tests/deriving/should_fail/deriving-via-fail.hs b/testsuite/tests/deriving/should_fail/deriving-via-fail.hs index 0cb521de7848..95c462a6ea4e 100644 --- a/testsuite/tests/deriving/should_fail/deriving-via-fail.hs +++ b/testsuite/tests/deriving/should_fail/deriving-via-fail.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE DerivingVia #-} {-# LANGUAGE ScopedTypeVariables #-} {-# LANGUAGE StandaloneDeriving #-} diff --git a/testsuite/tests/deriving/should_fail/deriving-via-fail.stderr b/testsuite/tests/deriving/should_fail/deriving-via-fail.stderr index 5179f53c0310..ea07442a8200 100644 --- a/testsuite/tests/deriving/should_fail/deriving-via-fail.stderr +++ b/testsuite/tests/deriving/should_fail/deriving-via-fail.stderr @@ -1,28 +1,28 @@ -deriving-via-fail.hs:9:34: error: +deriving-via-fail.hs:10:34: error: • Couldn't match representation of type ‘a’ with that of ‘b’ arising from the coercion of the method ‘showsPrec’ from type ‘Int -> Identity b -> ShowS’ to type ‘Int -> Foo1 a -> ShowS’ ‘a’ is a rigid type variable bound by the deriving clause for ‘Show (Foo1 a)’ - at deriving-via-fail.hs:9:34-37 + at deriving-via-fail.hs:10:34-37 ‘b’ is a rigid type variable bound by the deriving clause for ‘Show (Foo1 a)’ - at deriving-via-fail.hs:9:34-37 + at deriving-via-fail.hs:10:34-37 • When deriving the instance for (Show (Foo1 a)) -deriving-via-fail.hs:12:12: error: +deriving-via-fail.hs:13:12: error: • Cannot derive instance via ‘fooo’ Class ‘Category’ expects an argument of kind ‘* -> * -> *’, but ‘fooo’ has kind ‘*’ • In the newtype declaration for ‘Foo2’ -deriving-via-fail.hs:15:20: error: +deriving-via-fail.hs:16:20: error: • Couldn't match representation of type ‘a’ with that of ‘Foo3’ arising from the coercion of the method ‘==’ from type ‘a -> a -> Bool’ to type ‘Foo3 -> Foo3 -> Bool’ ‘a’ is a rigid type variable bound by the deriving clause for ‘Eq Foo3’ - at deriving-via-fail.hs:15:20-21 + at deriving-via-fail.hs:16:20-21 • When deriving the instance for (Eq Foo3) diff --git a/testsuite/tests/deriving/should_fail/deriving-via-fail4.hs b/testsuite/tests/deriving/should_fail/deriving-via-fail4.hs index 2e16abfa2024..e58ffca658ef 100644 --- a/testsuite/tests/deriving/should_fail/deriving-via-fail4.hs +++ b/testsuite/tests/deriving/should_fail/deriving-via-fail4.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE DerivingVia #-} {-# LANGUAGE FlexibleInstances #-} {-# LANGUAGE MultiParamTypeClasses #-} diff --git a/testsuite/tests/deriving/should_fail/deriving-via-fail4.stderr b/testsuite/tests/deriving/should_fail/deriving-via-fail4.stderr index 9c4ee1520985..9c1b305fbfe9 100644 --- a/testsuite/tests/deriving/should_fail/deriving-via-fail4.stderr +++ b/testsuite/tests/deriving/should_fail/deriving-via-fail4.stderr @@ -1,18 +1,18 @@ -deriving-via-fail4.hs:14:12: error: +deriving-via-fail4.hs:15:12: error: • Couldn't match representation of type ‘Int’ with that of ‘Char’ arising from the coercion of the method ‘==’ from type ‘Char -> Char -> Bool’ to type ‘F1 -> F1 -> Bool’ • When deriving the instance for (Eq F1) -deriving-via-fail4.hs:17:13: error: +deriving-via-fail4.hs:18:13: error: • Couldn't match representation of type ‘a’ with that of ‘a1’ arising from the coercion of the method ‘c’ from type ‘a -> a -> Bool’ to type ‘a -> F2 a1 -> Bool’ ‘a’ is a rigid type variable bound by the deriving clause for ‘C a (F2 a1)’ - at deriving-via-fail4.hs:17:13-15 + at deriving-via-fail4.hs:18:13-15 ‘a1’ is a rigid type variable bound by the deriving clause for ‘C a (F2 a1)’ - at deriving-via-fail4.hs:17:13-15 + at deriving-via-fail4.hs:18:13-15 • When deriving the instance for (C a (F2 a1)) diff --git a/testsuite/tests/deriving/should_fail/drvfail-functor1.hs b/testsuite/tests/deriving/should_fail/drvfail-functor1.hs index 94ebd925b8bb..aef52421e071 100644 --- a/testsuite/tests/deriving/should_fail/drvfail-functor1.hs +++ b/testsuite/tests/deriving/should_fail/drvfail-functor1.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module ShouldFail where -- Derive Functor without a DeriveFunctor language pragma diff --git a/testsuite/tests/deriving/should_fail/drvfail-functor1.stderr b/testsuite/tests/deriving/should_fail/drvfail-functor1.stderr index bff4d27a492e..07ce81f4abb9 100644 --- a/testsuite/tests/deriving/should_fail/drvfail-functor1.stderr +++ b/testsuite/tests/deriving/should_fail/drvfail-functor1.stderr @@ -1,5 +1,5 @@ -drvfail-functor1.hs:6:14: - Can't make a derived instance of ‘Functor List’: - You need DeriveFunctor to derive an instance for this class - In the data declaration for ‘List’ +drvfail-functor1.hs:7:14: error: + • Can't make a derived instance of ‘Functor List’: + You need DeriveFunctor to derive an instance for this class + • In the data declaration for ‘List’ diff --git a/testsuite/tests/deriving/should_fail/drvfail-functor2.hs b/testsuite/tests/deriving/should_fail/drvfail-functor2.hs index 77e17cf381b4..be5413f77390 100644 --- a/testsuite/tests/deriving/should_fail/drvfail-functor2.hs +++ b/testsuite/tests/deriving/should_fail/drvfail-functor2.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE DeriveFunctor, DatatypeContexts #-} module ShouldFail where diff --git a/testsuite/tests/deriving/should_fail/drvfail-functor2.stderr b/testsuite/tests/deriving/should_fail/drvfail-functor2.stderr index e0aa34656c7e..1c3a0238a433 100644 --- a/testsuite/tests/deriving/should_fail/drvfail-functor2.stderr +++ b/testsuite/tests/deriving/should_fail/drvfail-functor2.stderr @@ -1,31 +1,31 @@ -drvfail-functor2.hs:1:29: Warning: +drvfail-functor2.hs:2:29: warning: -XDatatypeContexts is deprecated: It was widely considered a misfeature, and has been removed from the Haskell language. -drvfail-functor2.hs:7:14: - Can't make a derived instance of ‘Functor InFunctionArgument’: - Constructor ‘InFunctionArgument’ must not use the type variable in a function argument - In the newtype declaration for ‘InFunctionArgument’ +drvfail-functor2.hs:8:14: error: + • Can't make a derived instance of ‘Functor InFunctionArgument’: + Constructor ‘InFunctionArgument’ must not use the type variable in a function argument + • In the newtype declaration for ‘InFunctionArgument’ -drvfail-functor2.hs:10:14: - Can't make a derived instance of ‘Functor OnSecondArg’: - Constructor ‘OnSecondArg’ must use the type variable only as the last argument of a data type - In the newtype declaration for ‘OnSecondArg’ +drvfail-functor2.hs:11:14: error: + • Can't make a derived instance of ‘Functor OnSecondArg’: + Constructor ‘OnSecondArg’ must use the type variable only as the last argument of a data type + • In the newtype declaration for ‘OnSecondArg’ -drvfail-functor2.hs:15:14: - Cannot derive well-kinded instance of form ‘Functor (NoArguments ...)’ - Class ‘Functor’ expects an argument of kind ‘* -> *’ - In the newtype declaration for ‘NoArguments’ +drvfail-functor2.hs:16:14: error: + • Cannot derive well-kinded instance of form ‘Functor (NoArguments ...)’ + Class ‘Functor’ expects an argument of kind ‘* -> *’ + • In the newtype declaration for ‘NoArguments’ -drvfail-functor2.hs:20:14: - Can't make a derived instance of ‘Functor StupidConstraint’: - Data type ‘StupidConstraint’ must not have a class context: Eq a - In the data declaration for ‘StupidConstraint’ +drvfail-functor2.hs:21:14: error: + • Can't make a derived instance of ‘Functor StupidConstraint’: + Data type ‘StupidConstraint’ must not have a class context: Eq a + • In the data declaration for ‘StupidConstraint’ -drvfail-functor2.hs:26:14: - No instance for (Functor NoFunctor) - arising from the first field of ‘UseNoFunctor’ (type ‘NoFunctor a’) - Possible fix: - use a standalone 'deriving instance' declaration, - so you can specify the instance context yourself - When deriving the instance for (Functor UseNoFunctor) +drvfail-functor2.hs:27:14: error: + • No instance for (Functor NoFunctor) + arising from the first field of ‘UseNoFunctor’ (type ‘NoFunctor a’) + Possible fix: + use a standalone 'deriving instance' declaration, + so you can specify the instance context yourself + • When deriving the instance for (Functor UseNoFunctor) diff --git a/testsuite/tests/deriving/should_fail/drvfail008.hs b/testsuite/tests/deriving/should_fail/drvfail008.hs index af8628b4d502..1636bd1353c8 100644 --- a/testsuite/tests/deriving/should_fail/drvfail008.hs +++ b/testsuite/tests/deriving/should_fail/drvfail008.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} -- Should fail without GeneralizedNewtypeDeriving -- Succeeds with GeneralizedNewtypeDeriving diff --git a/testsuite/tests/deriving/should_fail/drvfail008.stderr b/testsuite/tests/deriving/should_fail/drvfail008.stderr index dcd43eca623f..e942f087e75e 100644 --- a/testsuite/tests/deriving/should_fail/drvfail008.stderr +++ b/testsuite/tests/deriving/should_fail/drvfail008.stderr @@ -1,5 +1,5 @@ -drvfail008.hs:10:43: error: +drvfail008.hs:11:43: error: • Can't make a derived instance of ‘Monad M’: ‘Monad’ is not a stock derivable class (Eq, Show, etc.) Try GeneralizedNewtypeDeriving for GHC's newtype-deriving extension diff --git a/testsuite/tests/deriving/should_fail/drvfail015.hs b/testsuite/tests/deriving/should_fail/drvfail015.hs index 32d6134d3416..8f1235c0b851 100644 --- a/testsuite/tests/deriving/should_fail/drvfail015.hs +++ b/testsuite/tests/deriving/should_fail/drvfail015.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# OPTIONS_GHC -XStandaloneDeriving #-} module ShouldFail where diff --git a/testsuite/tests/deriving/should_fail/drvfail015.stderr b/testsuite/tests/deriving/should_fail/drvfail015.stderr index c38ff0045688..b731032fc39f 100644 --- a/testsuite/tests/deriving/should_fail/drvfail015.stderr +++ b/testsuite/tests/deriving/should_fail/drvfail015.stderr @@ -1,13 +1,13 @@ -drvfail015.hs:10:19: - Illegal instance declaration for ‘Eq T’ - (All instance types must be of the form (T t1 ... tn) - where T is not a synonym. - Use TypeSynonymInstances if you want to disable this.) - In the stand-alone deriving instance for ‘Eq T’ +drvfail015.hs:11:19: error: + • Illegal instance declaration for ‘Eq T’ + (All instance types must be of the form (T t1 ... tn) + where T is not a synonym. + Use TypeSynonymInstances if you want to disable this.) + • In the stand-alone deriving instance for ‘Eq T’ -drvfail015.hs:13:1: - Can't make a derived instance of ‘Eq Handle’: - The data constructors of ‘Handle’ are not all in scope - so you cannot derive an instance for it - In the stand-alone deriving instance for ‘Eq Handle’ +drvfail015.hs:14:1: error: + • Can't make a derived instance of ‘Eq Handle’: + The data constructors of ‘Handle’ are not all in scope + so you cannot derive an instance for it + • In the stand-alone deriving instance for ‘Eq Handle’ diff --git a/testsuite/tests/determinism/determ015/A.hs b/testsuite/tests/determinism/determ015/A.hs index 14b29170b1f8..403c489c7537 100644 --- a/testsuite/tests/determinism/determ015/A.hs +++ b/testsuite/tests/determinism/determ015/A.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE UnicodeSyntax #-} {-# LANGUAGE EmptyDataDecls #-} {-# LANGUAGE TypeOperators #-} diff --git a/testsuite/tests/ffi/should_fail/T3066.hs b/testsuite/tests/ffi/should_fail/T3066.hs index 2d719468439e..17f2914ea1da 100644 --- a/testsuite/tests/ffi/should_fail/T3066.hs +++ b/testsuite/tests/ffi/should_fail/T3066.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE ForeignFunctionInterface, RankNTypes #-} module Foo where diff --git a/testsuite/tests/ffi/should_fail/T3066.stderr b/testsuite/tests/ffi/should_fail/T3066.stderr index 3b6c3f9b4788..280905136ad2 100644 --- a/testsuite/tests/ffi/should_fail/T3066.stderr +++ b/testsuite/tests/ffi/should_fail/T3066.stderr @@ -1,6 +1,6 @@ -T3066.hs:6:1: - Unacceptable argument type in foreign declaration: - ‘forall u. Ptr ()’ is not a data type - When checking declaration: - foreign import ccall safe bla :: (forall u. X u) -> IO () +T3066.hs:7:1: error: + • Unacceptable argument type in foreign declaration: + ‘forall u. Ptr ()’ is not a data type + • When checking declaration: + foreign import ccall safe bla :: (forall u. X u) -> IO () diff --git a/testsuite/tests/gadt/T1999a.hs b/testsuite/tests/gadt/T1999a.hs index 494812ca2915..fcfca35ab2b1 100644 --- a/testsuite/tests/gadt/T1999a.hs +++ b/testsuite/tests/gadt/T1999a.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE GADTs #-} -- #1999 diff --git a/testsuite/tests/gadt/T3163.hs b/testsuite/tests/gadt/T3163.hs index 985ef9b1101a..1ff1eb6bf66a 100644 --- a/testsuite/tests/gadt/T3163.hs +++ b/testsuite/tests/gadt/T3163.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE GADTs, RankNTypes, ImpredicativeTypes #-} -- Test #3163 diff --git a/testsuite/tests/gadt/T3163.stderr b/testsuite/tests/gadt/T3163.stderr index 2ee6095e1b5d..c9b09f1fa093 100644 --- a/testsuite/tests/gadt/T3163.stderr +++ b/testsuite/tests/gadt/T3163.stderr @@ -1,5 +1,5 @@ -T3163.hs:8:5: error: +T3163.hs:9:5: error: • Illegal polymorphic type: forall s. s • In the definition of data constructor ‘Unreached’ In the data type declaration for ‘Taker’ diff --git a/testsuite/tests/gadt/gadtSyntaxFail001.hs b/testsuite/tests/gadt/gadtSyntaxFail001.hs index 8fd8bfdf5bcf..0b8269665444 100644 --- a/testsuite/tests/gadt/gadtSyntaxFail001.hs +++ b/testsuite/tests/gadt/gadtSyntaxFail001.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE GADTSyntax #-} diff --git a/testsuite/tests/gadt/gadtSyntaxFail001.stderr b/testsuite/tests/gadt/gadtSyntaxFail001.stderr index 9e3c0d4ffc4c..aad7b63e54ef 100644 --- a/testsuite/tests/gadt/gadtSyntaxFail001.stderr +++ b/testsuite/tests/gadt/gadtSyntaxFail001.stderr @@ -1,5 +1,5 @@ -gadtSyntaxFail001.hs:8:5: error: +gadtSyntaxFail001.hs:9:5: error: • Data constructor ‘C2’ has existential type variables, a context, or a specialised result type C2 :: forall a. a -> Char -> Foo a Int (Enable ExistentialQuantification or GADTs to allow this) diff --git a/testsuite/tests/gadt/gadtSyntaxFail002.hs b/testsuite/tests/gadt/gadtSyntaxFail002.hs index cb33d6795ed3..2f16c936d1c2 100644 --- a/testsuite/tests/gadt/gadtSyntaxFail002.hs +++ b/testsuite/tests/gadt/gadtSyntaxFail002.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE GADTSyntax #-} diff --git a/testsuite/tests/gadt/gadtSyntaxFail002.stderr b/testsuite/tests/gadt/gadtSyntaxFail002.stderr index 7b0251c7e16f..f144b2e24785 100644 --- a/testsuite/tests/gadt/gadtSyntaxFail002.stderr +++ b/testsuite/tests/gadt/gadtSyntaxFail002.stderr @@ -1,5 +1,5 @@ -gadtSyntaxFail002.hs:8:5: error: +gadtSyntaxFail002.hs:9:5: error: • Data constructor ‘C2’ has existential type variables, a context, or a specialised result type C2 :: forall a. a -> Char -> Foo a a (Enable ExistentialQuantification or GADTs to allow this) diff --git a/testsuite/tests/gadt/gadtSyntaxFail003.hs b/testsuite/tests/gadt/gadtSyntaxFail003.hs index 10c67200fc56..71c1bf33ac50 100644 --- a/testsuite/tests/gadt/gadtSyntaxFail003.hs +++ b/testsuite/tests/gadt/gadtSyntaxFail003.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE GADTSyntax #-} diff --git a/testsuite/tests/gadt/gadtSyntaxFail003.stderr b/testsuite/tests/gadt/gadtSyntaxFail003.stderr index 903624499a18..f5255aa4a2e9 100644 --- a/testsuite/tests/gadt/gadtSyntaxFail003.stderr +++ b/testsuite/tests/gadt/gadtSyntaxFail003.stderr @@ -1,5 +1,5 @@ -gadtSyntaxFail003.hs:7:5: error: +gadtSyntaxFail003.hs:8:5: error: • Data constructor ‘C1’ has existential type variables, a context, or a specialised result type C1 :: forall a c b. a -> Int -> c -> Foo b a (Enable ExistentialQuantification or GADTs to allow this) diff --git a/testsuite/tests/generics/GenShouldFail0.hs b/testsuite/tests/generics/GenShouldFail0.hs index cc1ef6ff421f..1e90a94fc44c 100644 --- a/testsuite/tests/generics/GenShouldFail0.hs +++ b/testsuite/tests/generics/GenShouldFail0.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE StandaloneDeriving #-} module ShouldFail0 where diff --git a/testsuite/tests/generics/GenShouldFail0.stderr b/testsuite/tests/generics/GenShouldFail0.stderr index 270c872f5605..90fe1bf3052b 100644 --- a/testsuite/tests/generics/GenShouldFail0.stderr +++ b/testsuite/tests/generics/GenShouldFail0.stderr @@ -1,5 +1,5 @@ -GenShouldFail0.hs:9:1: - Can't make a derived instance of ‘Generic X’: - You need DeriveGeneric to derive an instance for this class - In the stand-alone deriving instance for ‘Generic X’ +GenShouldFail0.hs:10:1: error: + • Can't make a derived instance of ‘Generic X’: + You need DeriveGeneric to derive an instance for this class + • In the stand-alone deriving instance for ‘Generic X’ diff --git a/testsuite/tests/generics/GenShouldFail1_0.hs b/testsuite/tests/generics/GenShouldFail1_0.hs index 15f059d65d80..180ac2f1a4c3 100644 --- a/testsuite/tests/generics/GenShouldFail1_0.hs +++ b/testsuite/tests/generics/GenShouldFail1_0.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE StandaloneDeriving #-} module ShouldFail1_0 where diff --git a/testsuite/tests/generics/GenShouldFail1_0.stderr b/testsuite/tests/generics/GenShouldFail1_0.stderr index e75404f8bb5b..26dfa8e4056f 100644 --- a/testsuite/tests/generics/GenShouldFail1_0.stderr +++ b/testsuite/tests/generics/GenShouldFail1_0.stderr @@ -1,5 +1,5 @@ -GenShouldFail1_0.hs:9:1: - Can't make a derived instance of ‘Generic1 X’: - You need DeriveGeneric to derive an instance for this class - In the stand-alone deriving instance for ‘Generic1 X’ +GenShouldFail1_0.hs:10:1: error: + • Can't make a derived instance of ‘Generic1 X’: + You need DeriveGeneric to derive an instance for this class + • In the stand-alone deriving instance for ‘Generic1 X’ diff --git a/testsuite/tests/generics/T10604/T10604_bad_variable_occurrence.hs b/testsuite/tests/generics/T10604/T10604_bad_variable_occurrence.hs index 53ad879702f2..3ae3bbc56533 100644 --- a/testsuite/tests/generics/T10604/T10604_bad_variable_occurrence.hs +++ b/testsuite/tests/generics/T10604/T10604_bad_variable_occurrence.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE DeriveGeneric #-} {-# LANGUAGE PolyKinds #-} module T10604_bad_variable_occurrence where diff --git a/testsuite/tests/generics/T10604/T10604_bad_variable_occurrence.stderr b/testsuite/tests/generics/T10604/T10604_bad_variable_occurrence.stderr index 26c6a5562a5b..a8ac7c747101 100644 --- a/testsuite/tests/generics/T10604/T10604_bad_variable_occurrence.stderr +++ b/testsuite/tests/generics/T10604/T10604_bad_variable_occurrence.stderr @@ -1,5 +1,5 @@ -T10604_bad_variable_occurrence.hs:8:12: error: +T10604_bad_variable_occurrence.hs:9:12: error: • Can't make a derived instance of ‘Generic1 Fix’: Constructor ‘In’ applies a type to an argument involving the last parameter but the applied type is not of kind * -> * diff --git a/testsuite/tests/generics/T10604/T10604_no_PolyKinds.hs b/testsuite/tests/generics/T10604/T10604_no_PolyKinds.hs index bdb98cab695b..50e7251717db 100644 --- a/testsuite/tests/generics/T10604/T10604_no_PolyKinds.hs +++ b/testsuite/tests/generics/T10604/T10604_no_PolyKinds.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE DeriveGeneric #-} {-# LANGUAGE KindSignatures #-} module T10604_no_PolyKinds where diff --git a/testsuite/tests/generics/T10604/T10604_no_PolyKinds.stderr b/testsuite/tests/generics/T10604/T10604_no_PolyKinds.stderr index 69bc591d0166..ca87502a90de 100644 --- a/testsuite/tests/generics/T10604/T10604_no_PolyKinds.stderr +++ b/testsuite/tests/generics/T10604/T10604_no_PolyKinds.stderr @@ -1,5 +1,5 @@ -T10604_no_PolyKinds.hs:7:35: error: +T10604_no_PolyKinds.hs:8:35: error: • Cannot derive well-kinded instance of form ‘Generic1 (F ...)’ (Perhaps you intended to use PolyKinds) Class ‘Generic1’ expects an argument of kind ‘* -> *’ diff --git a/testsuite/tests/generics/T5462No1.hs b/testsuite/tests/generics/T5462No1.hs index fc24f6343163..f1200208f886 100644 --- a/testsuite/tests/generics/T5462No1.hs +++ b/testsuite/tests/generics/T5462No1.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE FlexibleContexts #-} {-# LANGUAGE FlexibleInstances #-} {-# LANGUAGE DeriveGeneric #-} diff --git a/testsuite/tests/generics/T5462No1.stderr b/testsuite/tests/generics/T5462No1.stderr index c82f1b86ee15..0b718d648ee6 100644 --- a/testsuite/tests/generics/T5462No1.stderr +++ b/testsuite/tests/generics/T5462No1.stderr @@ -1,20 +1,20 @@ [1 of 2] Compiling GFunctor ( GFunctor/GFunctor.hs, out_T5462No1/GFunctor.o ) [2 of 2] Compiling T5462No1 ( T5462No1.hs, out_T5462No1/T5462No1.o ) -T5462No1.hs:24:42: error: - Can't make a derived instance of ‘GFunctor F’: - ‘GFunctor’ is not a stock derivable class (Eq, Show, etc.) - Try GeneralizedNewtypeDeriving for GHC's newtype-deriving extension - In the newtype declaration for ‘F’ - -T5462No1.hs:26:23: error: - Can't make a derived instance of ‘C1 G’: - ‘C1’ is not a stock derivable class (Eq, Show, etc.) - Try enabling DeriveAnyClass - In the data declaration for ‘G’ +T5462No1.hs:25:42: error: + • Can't make a derived instance of ‘GFunctor F’: + ‘GFunctor’ is not a stock derivable class (Eq, Show, etc.) + Try GeneralizedNewtypeDeriving for GHC's newtype-deriving extension + • In the newtype declaration for ‘F’ T5462No1.hs:27:23: error: - Can't make a derived instance of ‘C2 H’: - ‘C2’ is not a stock derivable class (Eq, Show, etc.) - Try enabling DeriveAnyClass - In the data declaration for ‘H’ + • Can't make a derived instance of ‘C1 G’: + ‘C1’ is not a stock derivable class (Eq, Show, etc.) + Try enabling DeriveAnyClass + • In the data declaration for ‘G’ + +T5462No1.hs:28:23: error: + • Can't make a derived instance of ‘C2 H’: + ‘C2’ is not a stock derivable class (Eq, Show, etc.) + Try enabling DeriveAnyClass + • In the data declaration for ‘H’ diff --git a/testsuite/tests/ghc-api/T7478/T7478.hs b/testsuite/tests/ghc-api/T7478/T7478.hs index 786a85964429..ce33e50daec9 100644 --- a/testsuite/tests/ghc-api/T7478/T7478.hs +++ b/testsuite/tests/ghc-api/T7478/T7478.hs @@ -1,3 +1,5 @@ +{-# LANGUAGE Haskell2010 #-} +{-# LANGUAGE NondecreasingIndentation #-} {-# LANGUAGE NamedFieldPuns #-} module Main (main) where diff --git a/testsuite/tests/ghc-api/downsweep/OldModLocation.hs b/testsuite/tests/ghc-api/downsweep/OldModLocation.hs index 9e03f925b686..153509f29efd 100644 --- a/testsuite/tests/ghc-api/downsweep/OldModLocation.hs +++ b/testsuite/tests/ghc-api/downsweep/OldModLocation.hs @@ -1,3 +1,5 @@ +{-# LANGUAGE Haskell2010 #-} +{-# LANGUAGE NondecreasingIndentation #-} {-# LANGUAGE ViewPatterns #-} import GHC diff --git a/testsuite/tests/ghci/T18071/T18071.hs b/testsuite/tests/ghci/T18071/T18071.hs index 1b0d53c33732..aa1387cf698c 100644 --- a/testsuite/tests/ghci/T18071/T18071.hs +++ b/testsuite/tests/ghci/T18071/T18071.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE FlexibleInstances #-} {-# LANGUAGE PolyKinds #-} {-# LANGUAGE QuantifiedConstraints #-} diff --git a/testsuite/tests/ghci/T18071/T18071.stdout b/testsuite/tests/ghci/T18071/T18071.stdout index 815aa1e24572..20411b0310b2 100644 --- a/testsuite/tests/ghci/T18071/T18071.stdout +++ b/testsuite/tests/ghci/T18071/T18071.stdout @@ -1 +1 @@ -instance [safe] MyShowProxy U -- Defined at T18071.hs:16:10 +instance [safe] MyShowProxy U -- Defined at T18071.hs:17:10 diff --git a/testsuite/tests/ghci/T18262/T18262.hs b/testsuite/tests/ghci/T18262/T18262.hs index 1734de0179ce..ce4bfe632fc5 100644 --- a/testsuite/tests/ghci/T18262/T18262.hs +++ b/testsuite/tests/ghci/T18262/T18262.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies, FlexibleInstances, DataKinds, UndecidableInstances #-} import GHC.TypeLits diff --git a/testsuite/tests/ghci/T18262/T18262.stdout b/testsuite/tests/ghci/T18262/T18262.stdout index 76d7e8a596e9..13868ead5a07 100644 --- a/testsuite/tests/ghci/T18262/T18262.stdout +++ b/testsuite/tests/ghci/T18262/T18262.stdout @@ -1 +1 @@ -instance [safe] Err 'B -- Defined at T18262.hs:10:10 +instance [safe] Err 'B -- Defined at T18262.hs:11:10 diff --git a/testsuite/tests/ghci/prog006/Boot1.hs b/testsuite/tests/ghci/prog006/Boot1.hs index 0625737342e5..7711a5a4bfcd 100644 --- a/testsuite/tests/ghci/prog006/Boot1.hs +++ b/testsuite/tests/ghci/prog006/Boot1.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module Boot where import A diff --git a/testsuite/tests/ghci/prog006/Boot2.hs b/testsuite/tests/ghci/prog006/Boot2.hs index 5e7297e448d2..cc1b36062ac5 100644 --- a/testsuite/tests/ghci/prog006/Boot2.hs +++ b/testsuite/tests/ghci/prog006/Boot2.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE ExistentialQuantification #-} module Boot where diff --git a/testsuite/tests/ghci/prog006/prog006.stderr b/testsuite/tests/ghci/prog006/prog006.stderr index aedba9717f69..8b23e548ed7d 100644 --- a/testsuite/tests/ghci/prog006/prog006.stderr +++ b/testsuite/tests/ghci/prog006/prog006.stderr @@ -1,5 +1,5 @@ -Boot.hs:5:13: error: +Boot.hs:6:13: error: • Data constructor ‘D’ has existential type variables, a context, or a specialised result type D :: forall n. Class n => n -> Data (Enable ExistentialQuantification or GADTs to allow this) diff --git a/testsuite/tests/ghci/scripts/T12447.script b/testsuite/tests/ghci/scripts/T12447.script index 3bdd3f4b73ee..826dec0b632d 100644 --- a/testsuite/tests/ghci/scripts/T12447.script +++ b/testsuite/tests/ghci/scripts/T12447.script @@ -1,3 +1,4 @@ +:set -XHaskell2010 :set -XRankNTypes -XConstraintKinds -XTypeApplications import Data.Typeable diff --git a/testsuite/tests/ghci/scripts/T12550.script b/testsuite/tests/ghci/scripts/T12550.script index 2834aeb7d915..53c0e3764169 100644 --- a/testsuite/tests/ghci/scripts/T12550.script +++ b/testsuite/tests/ghci/scripts/T12550.script @@ -1,3 +1,4 @@ +:set -XHaskell2010 :set -fprint-explicit-foralls -XKindSignatures -XExplicitNamespaces -XUnicodeSyntax :set -Wno-star-is-type import Data.Kind (type Type) diff --git a/testsuite/tests/ghci/scripts/T13202a.script b/testsuite/tests/ghci/scripts/T13202a.script index 107d332a6449..1f1a9908c9b1 100644 --- a/testsuite/tests/ghci/scripts/T13202a.script +++ b/testsuite/tests/ghci/scripts/T13202a.script @@ -1,3 +1,4 @@ +:set -XHaskell2010 import GHC.Records :set -XTypeApplications -XDataKinds let foo = getField @"name" diff --git a/testsuite/tests/ghci/scripts/T13202a.stderr b/testsuite/tests/ghci/scripts/T13202a.stderr index 8b1851f17599..0402e7df7d61 100644 --- a/testsuite/tests/ghci/scripts/T13202a.stderr +++ b/testsuite/tests/ghci/scripts/T13202a.stderr @@ -1,5 +1,5 @@ -<interactive>:3:5: error: +<interactive>:4:5: error: • Non type-variable argument in the constraint: HasField "name" r a (Use FlexibleContexts to permit this) • When checking the inferred type diff --git a/testsuite/tests/ghci/scripts/T13420.hs b/testsuite/tests/ghci/scripts/T13420.hs index 6b84e65cb219..5b911d8d4bac 100644 --- a/testsuite/tests/ghci/scripts/T13420.hs +++ b/testsuite/tests/ghci/scripts/T13420.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies #-} module T13420 where diff --git a/testsuite/tests/ghci/scripts/T13420.stdout b/testsuite/tests/ghci/scripts/T13420.stdout index 030b902677b8..9e8d7a6b7ffe 100644 --- a/testsuite/tests/ghci/scripts/T13420.stdout +++ b/testsuite/tests/ghci/scripts/T13420.stdout @@ -3,4 +3,4 @@ type family F a where F [Int] = Bool F [a] = Double F (a b) = Char - -- Defined at T13420.hs:4:1 + -- Defined at T13420.hs:5:1 diff --git a/testsuite/tests/ghci/scripts/T14969.script b/testsuite/tests/ghci/scripts/T14969.script index ab6af53c6b52..476f5bfc65f4 100644 --- a/testsuite/tests/ghci/scripts/T14969.script +++ b/testsuite/tests/ghci/scripts/T14969.script @@ -1 +1,2 @@ +:set -XHaskell2010 3 _ 4 diff --git a/testsuite/tests/ghci/scripts/T14969.stderr b/testsuite/tests/ghci/scripts/T14969.stderr index 13da943a3cd0..ee9b5d2de856 100644 --- a/testsuite/tests/ghci/scripts/T14969.stderr +++ b/testsuite/tests/ghci/scripts/T14969.stderr @@ -1,5 +1,5 @@ -<interactive>:1:1: error: +<interactive>:2:1: error: • Non type-variable argument in the constraint: Num (t2 -> t1 -> t3) (Use FlexibleContexts to permit this) diff --git a/testsuite/tests/ghci/scripts/T15546.script b/testsuite/tests/ghci/scripts/T15546.script index 76bcda783ed7..0a06c5c633dc 100644 --- a/testsuite/tests/ghci/scripts/T15546.script +++ b/testsuite/tests/ghci/scripts/T15546.script @@ -1,3 +1,4 @@ +:set -XHaskell2010 :set -XTypeFamilies type family E a b where E a a = (); E a b = Bool :info E diff --git a/testsuite/tests/ghci/scripts/T15546.stdout b/testsuite/tests/ghci/scripts/T15546.stdout index d14b442bb835..47ed331dfad7 100644 --- a/testsuite/tests/ghci/scripts/T15546.stdout +++ b/testsuite/tests/ghci/scripts/T15546.stdout @@ -2,10 +2,10 @@ type E :: * -> * -> * type family E a b where E a a = () E a b = Bool - -- Defined at <interactive>:2:1 + -- Defined at <interactive>:3:1 type E :: * -> * -> * type family E a b where {- #0 -} E a a = () {- #1 -} E a b = Bool -- incompatible with: #0 - -- Defined at <interactive>:2:1 + -- Defined at <interactive>:3:1 diff --git a/testsuite/tests/ghci/scripts/T18501.script b/testsuite/tests/ghci/scripts/T18501.script index 64975cbc468b..947cf936b39d 100644 --- a/testsuite/tests/ghci/scripts/T18501.script +++ b/testsuite/tests/ghci/scripts/T18501.script @@ -1,3 +1,4 @@ +:set -XHaskell2010 :set -XAllowAmbiguousTypes class Foo a where foo :: String :t foo diff --git a/testsuite/tests/ghci/scripts/T19279.stdout b/testsuite/tests/ghci/scripts/T19279.stdout index fe7fbbf9f85f..37e056e1aa95 100644 --- a/testsuite/tests/ghci/scripts/T19279.stdout +++ b/testsuite/tests/ghci/scripts/T19279.stdout @@ -1,3 +1,3 @@ -T :: * -> * +T :: k -> k = T -T :: * -> * +T :: k -> k diff --git a/testsuite/tests/ghci/scripts/T4087.hs b/testsuite/tests/ghci/scripts/T4087.hs index b992a9bb2049..818649450871 100644 --- a/testsuite/tests/ghci/scripts/T4087.hs +++ b/testsuite/tests/ghci/scripts/T4087.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE GADTs #-} module T4087 where diff --git a/testsuite/tests/ghci/scripts/T4087.stdout b/testsuite/tests/ghci/scripts/T4087.stdout index 8dafaa881db5..6b0bbb51a551 100644 --- a/testsuite/tests/ghci/scripts/T4087.stdout +++ b/testsuite/tests/ghci/scripts/T4087.stdout @@ -2,4 +2,4 @@ type role Equal nominal nominal type Equal :: * -> * -> * data Equal a b where Equal :: Equal a a - -- Defined at T4087.hs:5:1 + -- Defined at T4087.hs:6:1 diff --git a/testsuite/tests/ghci/scripts/T4175.hs b/testsuite/tests/ghci/scripts/T4175.hs index ef34a4891d8c..7ecd8e948511 100644 --- a/testsuite/tests/ghci/scripts/T4175.hs +++ b/testsuite/tests/ghci/scripts/T4175.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies #-} {-# LANGUAGE ConstraintKinds #-} module T4175 where diff --git a/testsuite/tests/ghci/scripts/T4175.stdout b/testsuite/tests/ghci/scripts/T4175.stdout index 52d8a688c7b4..9f93304ca98d 100644 --- a/testsuite/tests/ghci/scripts/T4175.stdout +++ b/testsuite/tests/ghci/scripts/T4175.stdout @@ -1,31 +1,31 @@ type A :: * -> * -> * type family A a b - -- Defined at T4175.hs:7:1 -type instance A (Maybe a) a = a -- Defined at T4175.hs:9:15 -type instance A Int Int = () -- Defined at T4175.hs:8:15 -type instance A (B a) b = () -- Defined at T4175.hs:10:15 + -- Defined at T4175.hs:8:1 +type instance A (Maybe a) a = a -- Defined at T4175.hs:10:15 +type instance A Int Int = () -- Defined at T4175.hs:9:15 +type instance A (B a) b = () -- Defined at T4175.hs:11:15 type B :: * -> * data family B a - -- Defined at T4175.hs:12:1 -instance [safe] G B -- Defined at T4175.hs:34:10 -type instance A (B a) b = () -- Defined at T4175.hs:10:15 -data instance B () = MkB -- Defined at T4175.hs:13:15 + -- Defined at T4175.hs:13:1 +instance [safe] G B -- Defined at T4175.hs:35:10 +type instance A (B a) b = () -- Defined at T4175.hs:11:15 +data instance B () = MkB -- Defined at T4175.hs:14:15 type C :: * -> Constraint class C a where type D :: * -> * -> * type family D a b - -- Defined at T4175.hs:16:5 -type instance D () () = Bool -- Defined at T4175.hs:22:10 -type instance D Int () = String -- Defined at T4175.hs:19:10 + -- Defined at T4175.hs:17:5 +type instance D () () = Bool -- Defined at T4175.hs:23:10 +type instance D Int () = String -- Defined at T4175.hs:20:10 type E :: * -> * type family E a where E () = Bool E Int = String - -- Defined at T4175.hs:24:1 + -- Defined at T4175.hs:25:1 type () :: * data () = () -- Defined in ‘GHC.Tuple’ -instance [safe] C () -- Defined at T4175.hs:21:10 +instance [safe] C () -- Defined at T4175.hs:22:10 instance Eq () -- Defined in ‘GHC.Classes’ instance Monoid () -- Defined in ‘GHC.Base’ instance Ord () -- Defined in ‘GHC.Classes’ @@ -34,9 +34,9 @@ instance Enum () -- Defined in ‘GHC.Enum’ instance Show () -- Defined in ‘GHC.Show’ instance Read () -- Defined in ‘GHC.Read’ instance Bounded () -- Defined in ‘GHC.Enum’ -type instance D () () = Bool -- Defined at T4175.hs:22:10 -type instance D Int () = String -- Defined at T4175.hs:19:10 -data instance B () = MkB -- Defined at T4175.hs:13:15 +type instance D () () = Bool -- Defined at T4175.hs:23:10 +type instance D Int () = String -- Defined at T4175.hs:20:10 +data instance B () = MkB -- Defined at T4175.hs:14:15 type Maybe :: * -> * data Maybe a = Nothing | Just a -- Defined in ‘GHC.Maybe’ @@ -53,11 +53,11 @@ instance MonadFail Maybe -- Defined in ‘Control.Monad.Fail’ instance Read a => Read (Maybe a) -- Defined in ‘GHC.Read’ instance Foldable Maybe -- Defined in ‘Data.Foldable’ instance Traversable Maybe -- Defined in ‘Data.Traversable’ -type instance A (Maybe a) a = a -- Defined at T4175.hs:9:15 +type instance A (Maybe a) a = a -- Defined at T4175.hs:10:15 type Int :: * data Int = GHC.Types.I# GHC.Prim.Int# -- Defined in ‘GHC.Types’ -instance [safe] C Int -- Defined at T4175.hs:18:10 +instance [safe] C Int -- Defined at T4175.hs:19:10 instance Eq Int -- Defined in ‘GHC.Classes’ instance Ord Int -- Defined in ‘GHC.Classes’ instance Enum Int -- Defined in ‘GHC.Enum’ @@ -67,9 +67,9 @@ instance Show Int -- Defined in ‘GHC.Show’ instance Read Int -- Defined in ‘GHC.Read’ instance Bounded Int -- Defined in ‘GHC.Enum’ instance Integral Int -- Defined in ‘GHC.Real’ -type instance D Int () = String -- Defined at T4175.hs:19:10 -type instance A Int Int = () -- Defined at T4175.hs:8:15 +type instance D Int () = String -- Defined at T4175.hs:20:10 +type instance A Int Int = () -- Defined at T4175.hs:9:15 type Z :: * -> Constraint class Z a - -- Defined at T4175.hs:28:1 -instance [safe] F (Z a) -- Defined at T4175.hs:31:10 + -- Defined at T4175.hs:29:1 +instance [safe] F (Z a) -- Defined at T4175.hs:32:10 diff --git a/testsuite/tests/ghci/scripts/T5417.hs b/testsuite/tests/ghci/scripts/T5417.hs index e86c07663749..bf5e87a80d41 100644 --- a/testsuite/tests/ghci/scripts/T5417.hs +++ b/testsuite/tests/ghci/scripts/T5417.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies #-} module T5417 where import qualified T5417a as C diff --git a/testsuite/tests/ghci/scripts/T5417.script b/testsuite/tests/ghci/scripts/T5417.script index d163d7df0452..c27a6f6c6c0d 100644 --- a/testsuite/tests/ghci/scripts/T5417.script +++ b/testsuite/tests/ghci/scripts/T5417.script @@ -1,3 +1,4 @@ +:set -XHaskell2010 :l T5417 :browse :info C.F diff --git a/testsuite/tests/ghci/scripts/T5417.stdout b/testsuite/tests/ghci/scripts/T5417.stdout index 163a9236de58..5227ac665191 100644 --- a/testsuite/tests/ghci/scripts/T5417.stdout +++ b/testsuite/tests/ghci/scripts/T5417.stdout @@ -12,4 +12,4 @@ class C.C1 a where type C.F :: * -> * data family C.F a -- Defined at T5417a.hs:7:5 -data instance C.F (B1 a) = B2 a -- Defined at T5417.hs:8:10 +data instance C.F (B1 a) = B2 a -- Defined at T5417.hs:9:10 diff --git a/testsuite/tests/ghci/scripts/T5820.hs b/testsuite/tests/ghci/scripts/T5820.hs index 99d36e5fc26c..de6598f805bc 100644 --- a/testsuite/tests/ghci/scripts/T5820.hs +++ b/testsuite/tests/ghci/scripts/T5820.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module T5820 where data Foo = Foo instance Eq Foo diff --git a/testsuite/tests/ghci/scripts/T5820.stderr b/testsuite/tests/ghci/scripts/T5820.stderr index 3f46fdbc47e0..370aa6d95cba 100644 --- a/testsuite/tests/ghci/scripts/T5820.stderr +++ b/testsuite/tests/ghci/scripts/T5820.stderr @@ -1,5 +1,5 @@ -T5820.hs:3:10: warning: [-Wmissing-methods (in -Wdefault)] +T5820.hs:4:10: warning: [-Wmissing-methods (in -Wdefault)] • No explicit implementation for either ‘==’ or ‘/=’ • In the instance declaration for ‘Eq Foo’ diff --git a/testsuite/tests/ghci/scripts/T5820.stdout b/testsuite/tests/ghci/scripts/T5820.stdout index faa5f6fc7625..4940da3f2d7a 100644 --- a/testsuite/tests/ghci/scripts/T5820.stdout +++ b/testsuite/tests/ghci/scripts/T5820.stdout @@ -1,8 +1,8 @@ type Foo :: * data Foo = Foo - -- Defined at T5820.hs:2:1 -instance [safe] Eq Foo -- Defined at T5820.hs:3:10 + -- Defined at T5820.hs:3:1 +instance [safe] Eq Foo -- Defined at T5820.hs:4:10 type Foo :: * data Foo = Foo - -- Defined at T5820.hs:2:1 -instance [safe] Eq Foo -- Defined at T5820.hs:3:10 + -- Defined at T5820.hs:3:1 +instance [safe] Eq Foo -- Defined at T5820.hs:4:10 diff --git a/testsuite/tests/ghci/scripts/T7939.hs b/testsuite/tests/ghci/scripts/T7939.hs index 04a1f1a62378..493c6538d138 100644 --- a/testsuite/tests/ghci/scripts/T7939.hs +++ b/testsuite/tests/ghci/scripts/T7939.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies, PolyKinds, DataKinds, TypeOperators #-} module T7939 where import Data.Kind (Type) diff --git a/testsuite/tests/ghci/scripts/T7939.stdout b/testsuite/tests/ghci/scripts/T7939.stdout index 93739d04dccd..0d9e4d363ce3 100644 --- a/testsuite/tests/ghci/scripts/T7939.stdout +++ b/testsuite/tests/ghci/scripts/T7939.stdout @@ -2,32 +2,32 @@ type Foo :: forall {k}. k -> Constraint class Foo a where type Bar :: forall {k}. k -> * -> * type family Bar a b - -- Defined at T7939.hs:6:4 + -- Defined at T7939.hs:7:4 Bar :: k -> * -> * type F :: * -> * type family F a - -- Defined at T7939.hs:8:1 -type instance F Int = Bool -- Defined at T7939.hs:9:15 + -- Defined at T7939.hs:9:1 +type instance F Int = Bool -- Defined at T7939.hs:10:15 F :: * -> * type G :: * -> * type family G a where G Int = Bool - -- Defined at T7939.hs:11:1 + -- Defined at T7939.hs:12:1 G :: * -> * type H :: Bool -> Bool type family H a where H 'False = 'True - -- Defined at T7939.hs:14:1 + -- Defined at T7939.hs:15:1 H :: Bool -> Bool type J :: forall {k}. [k] -> Bool type family J a where J '[] = 'False forall k (h :: k) (t :: [k]). J (h : t) = 'True - -- Defined at T7939.hs:17:1 + -- Defined at T7939.hs:18:1 J :: [k] -> Bool type K :: forall {a}. [a] -> Maybe a type family K a1 where K '[] = 'Nothing forall a (h :: a) (t :: [a]). K (h : t) = 'Just h - -- Defined at T7939.hs:21:1 + -- Defined at T7939.hs:22:1 K :: [a] -> Maybe a diff --git a/testsuite/tests/ghci/scripts/T9293.hs b/testsuite/tests/ghci/scripts/T9293.hs index f7329c97e543..3a5d3d898662 100644 --- a/testsuite/tests/ghci/scripts/T9293.hs +++ b/testsuite/tests/ghci/scripts/T9293.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module Test where data T a where C :: T Int diff --git a/testsuite/tests/ghci/scripts/T9293.script b/testsuite/tests/ghci/scripts/T9293.script index c2fbf46cd749..c4719e26e4db 100644 --- a/testsuite/tests/ghci/scripts/T9293.script +++ b/testsuite/tests/ghci/scripts/T9293.script @@ -1,3 +1,4 @@ +:set -XHaskell2010 :set putStrLn "Should fail, GADTs is not enabled" diff --git a/testsuite/tests/ghci/scripts/T9293.stderr b/testsuite/tests/ghci/scripts/T9293.stderr index 4a72589688f6..8f46cee2d122 100644 --- a/testsuite/tests/ghci/scripts/T9293.stderr +++ b/testsuite/tests/ghci/scripts/T9293.stderr @@ -1,17 +1,17 @@ -<interactive>:4:1: error: +<interactive>:5:1: error: • Illegal generalised algebraic data declaration for ‘T’ (Enable the GADTs extension to allow this) • In the data declaration for ‘T’ -ghci057.hs:3:3: error: +ghci057.hs:4:3: error: • Data constructor ‘C’ has existential type variables, a context, or a specialised result type C :: T Int (Enable ExistentialQuantification or GADTs to allow this) • In the definition of data constructor ‘C’ In the data type declaration for ‘T’ -ghci057.hs:3:3: error: +ghci057.hs:4:3: error: • Data constructor ‘C’ has existential type variables, a context, or a specialised result type C :: T Int (Enable ExistentialQuantification or GADTs to allow this) diff --git a/testsuite/tests/ghci/scripts/T9293.stdout b/testsuite/tests/ghci/scripts/T9293.stdout index 78c1ec819d16..15c36fb34e5e 100644 --- a/testsuite/tests/ghci/scripts/T9293.stdout +++ b/testsuite/tests/ghci/scripts/T9293.stdout @@ -1,8 +1,6 @@ options currently set: none. base language is: Haskell2010 with the following modifiers: - -XNoDatatypeContexts - -XNondecreasingIndentation GHCi-specific dynamic flag settings: other dynamic, non-language, flag settings: -fno-diagnostics-show-caret @@ -20,11 +18,9 @@ Should fail, GADTs is not enabled options currently set: none. base language is: Haskell2010 with the following modifiers: - -XNoDatatypeContexts -XGADTSyntax -XGADTs -XMonoLocalBinds - -XNondecreasingIndentation GHCi-specific dynamic flag settings: other dynamic, non-language, flag settings: -fno-diagnostics-show-caret @@ -42,10 +38,8 @@ Should work, GADTs is in force from :set options currently set: none. base language is: Haskell2010 with the following modifiers: - -XNoDatatypeContexts -XGADTSyntax -XMonoLocalBinds - -XNondecreasingIndentation GHCi-specific dynamic flag settings: other dynamic, non-language, flag settings: -fno-diagnostics-show-caret @@ -62,13 +56,11 @@ warning settings: Should fail, GADTs is now disabled base language is: Haskell2010 with the following modifiers: - -XNoDatatypeContexts -XExtendedDefaultRules -XGADTSyntax -XGADTs -XMonoLocalBinds -XNoMonomorphismRestriction - -XNondecreasingIndentation GHCi-specific dynamic flag settings: other dynamic, non-language, flag settings: -fno-diagnostics-show-caret diff --git a/testsuite/tests/ghci/scripts/ghci019.hs b/testsuite/tests/ghci/scripts/ghci019.hs index 14cf726c861e..94d5664f68b2 100644 --- a/testsuite/tests/ghci/scripts/ghci019.hs +++ b/testsuite/tests/ghci/scripts/ghci019.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} -- #1581 -- Even though Eq is not in scope unqualified, we want to -- see the Eq instance of Foo when we say :i Foo diff --git a/testsuite/tests/ghci/scripts/ghci019.stderr b/testsuite/tests/ghci/scripts/ghci019.stderr index 0d3378ec8eb7..51d5a0123f68 100644 --- a/testsuite/tests/ghci/scripts/ghci019.stderr +++ b/testsuite/tests/ghci/scripts/ghci019.stderr @@ -1,5 +1,5 @@ -ghci019.hs:9:10: warning: [-Wmissing-methods (in -Wdefault)] +ghci019.hs:10:10: warning: [-Wmissing-methods (in -Wdefault)] • No explicit implementation for either ‘Prelude.==’ or ‘Prelude./=’ • In the instance declaration for ‘Prelude.Eq Foo’ diff --git a/testsuite/tests/ghci/scripts/ghci019.stdout b/testsuite/tests/ghci/scripts/ghci019.stdout index 0a9fefb77bf6..ddcbafebb911 100644 --- a/testsuite/tests/ghci/scripts/ghci019.stdout +++ b/testsuite/tests/ghci/scripts/ghci019.stdout @@ -1,4 +1,4 @@ type Foo :: * data Foo = Foo - -- Defined at ghci019.hs:8:1 -instance [safe] Prelude.Eq Foo -- Defined at ghci019.hs:9:10 + -- Defined at ghci019.hs:9:1 +instance [safe] Prelude.Eq Foo -- Defined at ghci019.hs:10:10 diff --git a/testsuite/tests/ghci/scripts/ghci024.stdout b/testsuite/tests/ghci/scripts/ghci024.stdout index bd8ee9361e56..7cf36ac04135 100644 --- a/testsuite/tests/ghci/scripts/ghci024.stdout +++ b/testsuite/tests/ghci/scripts/ghci024.stdout @@ -1,9 +1,7 @@ ~~~~~~~~~~ Testing :set options currently set: none. -base language is: Haskell2010 +base language is: GHC2021 with the following modifiers: - -XNoDatatypeContexts - -XNondecreasingIndentation GHCi-specific dynamic flag settings: other dynamic, non-language, flag settings: -fno-diagnostics-show-caret @@ -19,7 +17,7 @@ warning settings: -Wcompat-unqualified-imports ~~~~~~~~~~ Testing :set -a options currently set: none. -base language is: Haskell2010 +base language is: GHC2021 all active language options: GHCi-specific dynamic flag settings: -fno-print-explicit-foralls @@ -27,16 +25,12 @@ other dynamic, non-language, flag settings: warning settings: -Wno-implicit-prelude ~~~~~~~~~~ Testing :show languages -base language is: Haskell2010 +base language is: GHC2021 with the following modifiers: - -XNoDatatypeContexts - -XNondecreasingIndentation ~~~~~~~~~~ Testing :show languages, with -XMagicHash -base language is: Haskell2010 +base language is: GHC2021 with the following modifiers: - -XNoDatatypeContexts -XMagicHash - -XNondecreasingIndentation ~~~~~~~~~~ Testing :show packages active package flags: none ~~~~~~~~~~ Testing :show packages, including the ghc package diff --git a/testsuite/tests/ghci/scripts/ghci025.hs b/testsuite/tests/ghci/scripts/ghci025.hs index b556509aa69f..abb6b3d49071 100644 --- a/testsuite/tests/ghci/scripts/ghci025.hs +++ b/testsuite/tests/ghci/scripts/ghci025.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE RankNTypes, MultiParamTypeClasses #-} {-# LANGUAGE AllowAmbiguousTypes #-} -- c3 is ambiguous! diff --git a/testsuite/tests/ghci/scripts/ghci057.hs b/testsuite/tests/ghci/scripts/ghci057.hs index 2a6b836d80e0..23bad888bcae 100644 --- a/testsuite/tests/ghci/scripts/ghci057.hs +++ b/testsuite/tests/ghci/scripts/ghci057.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module Test where data T a where C :: T Int diff --git a/testsuite/tests/ghci/scripts/ghci057.script b/testsuite/tests/ghci/scripts/ghci057.script index 547fce52d7ca..db77b80cb166 100644 --- a/testsuite/tests/ghci/scripts/ghci057.script +++ b/testsuite/tests/ghci/scripts/ghci057.script @@ -1,3 +1,4 @@ +:set -XHaskell2010 :set putStrLn "Should fail, GADTs is not enabled" diff --git a/testsuite/tests/ghci/scripts/ghci057.stderr b/testsuite/tests/ghci/scripts/ghci057.stderr index 4a72589688f6..8f46cee2d122 100644 --- a/testsuite/tests/ghci/scripts/ghci057.stderr +++ b/testsuite/tests/ghci/scripts/ghci057.stderr @@ -1,17 +1,17 @@ -<interactive>:4:1: error: +<interactive>:5:1: error: • Illegal generalised algebraic data declaration for ‘T’ (Enable the GADTs extension to allow this) • In the data declaration for ‘T’ -ghci057.hs:3:3: error: +ghci057.hs:4:3: error: • Data constructor ‘C’ has existential type variables, a context, or a specialised result type C :: T Int (Enable ExistentialQuantification or GADTs to allow this) • In the definition of data constructor ‘C’ In the data type declaration for ‘T’ -ghci057.hs:3:3: error: +ghci057.hs:4:3: error: • Data constructor ‘C’ has existential type variables, a context, or a specialised result type C :: T Int (Enable ExistentialQuantification or GADTs to allow this) diff --git a/testsuite/tests/ghci/scripts/ghci057.stdout b/testsuite/tests/ghci/scripts/ghci057.stdout index 78c1ec819d16..15c36fb34e5e 100644 --- a/testsuite/tests/ghci/scripts/ghci057.stdout +++ b/testsuite/tests/ghci/scripts/ghci057.stdout @@ -1,8 +1,6 @@ options currently set: none. base language is: Haskell2010 with the following modifiers: - -XNoDatatypeContexts - -XNondecreasingIndentation GHCi-specific dynamic flag settings: other dynamic, non-language, flag settings: -fno-diagnostics-show-caret @@ -20,11 +18,9 @@ Should fail, GADTs is not enabled options currently set: none. base language is: Haskell2010 with the following modifiers: - -XNoDatatypeContexts -XGADTSyntax -XGADTs -XMonoLocalBinds - -XNondecreasingIndentation GHCi-specific dynamic flag settings: other dynamic, non-language, flag settings: -fno-diagnostics-show-caret @@ -42,10 +38,8 @@ Should work, GADTs is in force from :set options currently set: none. base language is: Haskell2010 with the following modifiers: - -XNoDatatypeContexts -XGADTSyntax -XMonoLocalBinds - -XNondecreasingIndentation GHCi-specific dynamic flag settings: other dynamic, non-language, flag settings: -fno-diagnostics-show-caret @@ -62,13 +56,11 @@ warning settings: Should fail, GADTs is now disabled base language is: Haskell2010 with the following modifiers: - -XNoDatatypeContexts -XExtendedDefaultRules -XGADTSyntax -XGADTs -XMonoLocalBinds -XNoMonomorphismRestriction - -XNondecreasingIndentation GHCi-specific dynamic flag settings: other dynamic, non-language, flag settings: -fno-diagnostics-show-caret diff --git a/testsuite/tests/ghci/scripts/ghci064.hs b/testsuite/tests/ghci/scripts/ghci064.hs index 152836d2707e..c2c2e32b691a 100644 --- a/testsuite/tests/ghci/scripts/ghci064.hs +++ b/testsuite/tests/ghci/scripts/ghci064.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE FlexibleInstances, TypeFamilies #-} import Data.Kind (Type) diff --git a/testsuite/tests/ghci/scripts/ghci064.stdout b/testsuite/tests/ghci/scripts/ghci064.stdout index d527dde6c414..0fa911e35129 100644 --- a/testsuite/tests/ghci/scripts/ghci064.stdout +++ b/testsuite/tests/ghci/scripts/ghci064.stdout @@ -25,12 +25,12 @@ instance Show w => Show [w] -- Defined in ‘GHC.Show’ instance Read w => Read [w] -- Defined in ‘GHC.Read’ instance GHC.Generics.Generic [w] -- Defined in ‘GHC.Generics’ instance [safe] MyShow w => MyShow [w] - -- Defined at ghci064.hs:7:10 + -- Defined at ghci064.hs:8:10 instance Monoid [T] -- Defined in ‘GHC.Base’ instance Semigroup [T] -- Defined in ‘GHC.Base’ instance GHC.Generics.Generic [T] -- Defined in ‘GHC.Generics’ -instance [safe] MyShow [T] -- Defined at ghci064.hs:7:10 -instance [safe] MyShow [T] -- Defined at ghci064.hs:15:10 +instance [safe] MyShow [T] -- Defined at ghci064.hs:8:10 +instance [safe] MyShow [T] -- Defined at ghci064.hs:16:10 instance Eq Bool -- Defined in ‘GHC.Classes’ instance Ord Bool -- Defined in ‘GHC.Classes’ instance Enum Bool -- Defined in ‘GHC.Enum’ diff --git a/testsuite/tests/ghci/scripts/ghci065.stdout b/testsuite/tests/ghci/scripts/ghci065.stdout index 4c6f40c72c55..39b990b04ce7 100644 --- a/testsuite/tests/ghci/scripts/ghci065.stdout +++ b/testsuite/tests/ghci/scripts/ghci065.stdout @@ -26,7 +26,7 @@ func3 :: Int -> Int -> Int Here's multiple line comment for func3. PatSyn :: Int -- Pattern synonym defined at ghci065.hs:54:1 This is the haddock comment of a pattern synonym -TyCl :: * -> Constraint -- Class defined at ghci065.hs:57:1 +TyCl :: k -> Constraint -- Class defined at ghci065.hs:57:1 This is the haddock comment of a type class TyFam :: * -> * -- Type constructor defined at ghci065.hs:60:1 This is the haddock comment of a type family diff --git a/testsuite/tests/ghci/should_run/T10857a.stdout b/testsuite/tests/ghci/should_run/T10857a.stdout index a37151f06261..51f30615f10f 100644 --- a/testsuite/tests/ghci/should_run/T10857a.stdout +++ b/testsuite/tests/ghci/should_run/T10857a.stdout @@ -1,6 +1,4 @@ -base language is: Haskell2010 +base language is: GHC2021 with the following modifiers: - -XNoDatatypeContexts -XExtendedDefaultRules -XNoMonomorphismRestriction - -XNondecreasingIndentation diff --git a/testsuite/tests/ghci/should_run/T10857b.stdout b/testsuite/tests/ghci/should_run/T10857b.stdout index 2619fae00d88..bcc6fdd383b3 100644 --- a/testsuite/tests/ghci/should_run/T10857b.stdout +++ b/testsuite/tests/ghci/should_run/T10857b.stdout @@ -1,4 +1,2 @@ -base language is: Haskell2010 +base language is: GHC2021 with the following modifiers: - -XNoDatatypeContexts - -XNondecreasingIndentation diff --git a/testsuite/tests/ghci/should_run/T12525.stdout b/testsuite/tests/ghci/should_run/T12525.stdout index a00ffea4e378..ef48679f949a 100644 --- a/testsuite/tests/ghci/should_run/T12525.stdout +++ b/testsuite/tests/ghci/should_run/T12525.stdout @@ -1,4 +1,4 @@ x :: () = () y :: () = () -type Foo :: * -> Constraint +type Foo :: forall {k}. k -> Constraint class Foo a diff --git a/testsuite/tests/hiefile/should_compile/hie002.hs b/testsuite/tests/hiefile/should_compile/hie002.hs index 41146c7f7064..157d0eb6c643 100644 --- a/testsuite/tests/hiefile/should_compile/hie002.hs +++ b/testsuite/tests/hiefile/should_compile/hie002.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# OPTIONS_GHC -w #-} {-# OPTIONS -XMagicHash -XBangPatterns #-} module Grammar where diff --git a/testsuite/tests/indexed-types/should_compile/ClosedFam2.hs b/testsuite/tests/indexed-types/should_compile/ClosedFam2.hs index fb7d67b2f5aa..acd4720aab91 100644 --- a/testsuite/tests/indexed-types/should_compile/ClosedFam2.hs +++ b/testsuite/tests/indexed-types/should_compile/ClosedFam2.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies #-} module ClosedFam2 where diff --git a/testsuite/tests/indexed-types/should_compile/ClosedFam2.hs-boot b/testsuite/tests/indexed-types/should_compile/ClosedFam2.hs-boot index f13bf46d6e47..976c97b4ffa7 100644 --- a/testsuite/tests/indexed-types/should_compile/ClosedFam2.hs-boot +++ b/testsuite/tests/indexed-types/should_compile/ClosedFam2.hs-boot @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies #-} module ClosedFam2 where diff --git a/testsuite/tests/indexed-types/should_compile/ClosedFam2a.hs b/testsuite/tests/indexed-types/should_compile/ClosedFam2a.hs index b259f6e8f8d2..0a9e21b11742 100644 --- a/testsuite/tests/indexed-types/should_compile/ClosedFam2a.hs +++ b/testsuite/tests/indexed-types/should_compile/ClosedFam2a.hs @@ -1,2 +1,3 @@ +{-# LANGUAGE Haskell2010 #-} module ClosedFam2a where import {-# SOURCE #-} ClosedFam2 diff --git a/testsuite/tests/indexed-types/should_compile/IndTypesPerf.hs b/testsuite/tests/indexed-types/should_compile/IndTypesPerf.hs index 30c92c3a88c4..ed06a7918976 100644 --- a/testsuite/tests/indexed-types/should_compile/IndTypesPerf.hs +++ b/testsuite/tests/indexed-types/should_compile/IndTypesPerf.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} -- This used lots of memory, and took a long time to compile, with GHC 6.12: -- http://www.haskell.org/pipermail/glasgow-haskell-users/2010-May/018835.html diff --git a/testsuite/tests/indexed-types/should_compile/IndTypesPerfMerge.hs b/testsuite/tests/indexed-types/should_compile/IndTypesPerfMerge.hs index a022c36a8535..a7c16b725459 100644 --- a/testsuite/tests/indexed-types/should_compile/IndTypesPerfMerge.hs +++ b/testsuite/tests/indexed-types/should_compile/IndTypesPerfMerge.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE EmptyDataDecls, TypeFamilies, UndecidableInstances, ScopedTypeVariables, TypeOperators, FlexibleInstances, NoMonomorphismRestriction, diff --git a/testsuite/tests/indexed-types/should_compile/InstEqContext2.hs b/testsuite/tests/indexed-types/should_compile/InstEqContext2.hs index 0140d3e74eda..ea356a44ad20 100644 --- a/testsuite/tests/indexed-types/should_compile/InstEqContext2.hs +++ b/testsuite/tests/indexed-types/should_compile/InstEqContext2.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# OPTIONS_GHC -fno-warn-redundant-constraints #-} {-# LANGUAGE TypeFamilies, EmptyDataDecls #-} diff --git a/testsuite/tests/indexed-types/should_compile/Roman1.hs b/testsuite/tests/indexed-types/should_compile/Roman1.hs index 46f26a81967a..ef053c4902b2 100644 --- a/testsuite/tests/indexed-types/should_compile/Roman1.hs +++ b/testsuite/tests/indexed-types/should_compile/Roman1.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies, RankNTypes #-} -- This test made the type checker produce an diff --git a/testsuite/tests/indexed-types/should_compile/Simple14.hs b/testsuite/tests/indexed-types/should_compile/Simple14.hs index dba26194f1b5..bedf5bb3e7c5 100644 --- a/testsuite/tests/indexed-types/should_compile/Simple14.hs +++ b/testsuite/tests/indexed-types/should_compile/Simple14.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies, RankNTypes, FlexibleContexts, ScopedTypeVariables #-} module Simple14 where diff --git a/testsuite/tests/indexed-types/should_compile/Simple14.stderr b/testsuite/tests/indexed-types/should_compile/Simple14.stderr index 6159b088986f..7489ffce5a04 100644 --- a/testsuite/tests/indexed-types/should_compile/Simple14.stderr +++ b/testsuite/tests/indexed-types/should_compile/Simple14.stderr @@ -1,5 +1,5 @@ -Simple14.hs:19:27: error: +Simple14.hs:20:27: error: • Couldn't match type ‘z0’ with ‘n’ Expected: EQ_ z0 z0 Actual: EQ_ m n @@ -7,15 +7,15 @@ Simple14.hs:19:27: error: inside the constraints: Maybe m ~ Maybe n bound by a type expected by the context: (Maybe m ~ Maybe n) => EQ_ z0 z0 - at Simple14.hs:19:26-41 + at Simple14.hs:20:26-41 ‘n’ is a rigid type variable bound by the type signature for: foo :: forall m n. EQ_ (Maybe m) (Maybe n) - at Simple14.hs:18:1-42 + at Simple14.hs:19:1-42 • In the second argument of ‘eqE’, namely ‘(eqI :: EQ_ m n)’ In the expression: x `eqE` (eqI :: EQ_ m n) In the first argument of ‘ntI’, namely ‘(\ x -> x `eqE` (eqI :: EQ_ m n))’ • Relevant bindings include - x :: EQ_ (Maybe m) (Maybe n) (bound at Simple14.hs:19:13) - foo :: EQ_ (Maybe m) (Maybe n) (bound at Simple14.hs:19:1) + x :: EQ_ (Maybe m) (Maybe n) (bound at Simple14.hs:20:13) + foo :: EQ_ (Maybe m) (Maybe n) (bound at Simple14.hs:20:1) diff --git a/testsuite/tests/indexed-types/should_compile/T11361.hs b/testsuite/tests/indexed-types/should_compile/T11361.hs index 89153d4d0b37..75347347905d 100644 --- a/testsuite/tests/indexed-types/should_compile/T11361.hs +++ b/testsuite/tests/indexed-types/should_compile/T11361.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies #-} {-# LANGUAGE UndecidableInstances #-} -- this is needed because |FamHelper a x| /< |Fam a x| diff --git a/testsuite/tests/indexed-types/should_compile/T14554.hs b/testsuite/tests/indexed-types/should_compile/T14554.hs index 6049b1934ed8..e101fbdc7491 100644 --- a/testsuite/tests/indexed-types/should_compile/T14554.hs +++ b/testsuite/tests/indexed-types/should_compile/T14554.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# Language UndecidableInstances, DataKinds, TypeOperators, TypeFamilies, PolyKinds, GADTs, LambdaCase, ScopedTypeVariables #-} diff --git a/testsuite/tests/indexed-types/should_compile/T15122.hs b/testsuite/tests/indexed-types/should_compile/T15122.hs index c05bd3a8a023..49a3de642d32 100644 --- a/testsuite/tests/indexed-types/should_compile/T15122.hs +++ b/testsuite/tests/indexed-types/should_compile/T15122.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE GADTs #-} {-# LANGUAGE TypeFamilies #-} {-# LANGUAGE TypeInType #-} diff --git a/testsuite/tests/indexed-types/should_compile/T15352.hs b/testsuite/tests/indexed-types/should_compile/T15352.hs index d83512f085e5..25c4640809cf 100644 --- a/testsuite/tests/indexed-types/should_compile/T15352.hs +++ b/testsuite/tests/indexed-types/should_compile/T15352.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeInType #-} -- or PolyKinds {-# LANGUAGE MultiParamTypeClasses #-} {-# LANGUAGE TypeFamilies #-} diff --git a/testsuite/tests/indexed-types/should_compile/T16110_Compile.hs b/testsuite/tests/indexed-types/should_compile/T16110_Compile.hs index f05a4513fb04..ce73dba6a7fa 100644 --- a/testsuite/tests/indexed-types/should_compile/T16110_Compile.hs +++ b/testsuite/tests/indexed-types/should_compile/T16110_Compile.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE ScopedTypeVariables #-} {-# LANGUAGE TypeFamilies #-} module T16110_Compile where diff --git a/testsuite/tests/indexed-types/should_compile/T16356_Compile1.hs b/testsuite/tests/indexed-types/should_compile/T16356_Compile1.hs index 74dee38ac45a..6622d513d7f8 100644 --- a/testsuite/tests/indexed-types/should_compile/T16356_Compile1.hs +++ b/testsuite/tests/indexed-types/should_compile/T16356_Compile1.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE FlexibleInstances #-} {-# LANGUAGE PolyKinds #-} {-# LANGUAGE TypeApplications #-} diff --git a/testsuite/tests/indexed-types/should_compile/T17008b.hs b/testsuite/tests/indexed-types/should_compile/T17008b.hs index 25763684e4c3..7116c1d441dd 100644 --- a/testsuite/tests/indexed-types/should_compile/T17008b.hs +++ b/testsuite/tests/indexed-types/should_compile/T17008b.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeApplications #-} {-# LANGUAGE TypeFamilies #-} {-# LANGUAGE TypeInType #-} diff --git a/testsuite/tests/indexed-types/should_compile/T4120.hs b/testsuite/tests/indexed-types/should_compile/T4120.hs index 180472232fda..8e8e41f3221a 100644 --- a/testsuite/tests/indexed-types/should_compile/T4120.hs +++ b/testsuite/tests/indexed-types/should_compile/T4120.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE RankNTypes, TypeFamilies #-} -- Unification yielding a coercion under a forall diff --git a/testsuite/tests/indexed-types/should_compile/T4484.hs b/testsuite/tests/indexed-types/should_compile/T4484.hs index 203f19a44021..45add2ad4217 100644 --- a/testsuite/tests/indexed-types/should_compile/T4484.hs +++ b/testsuite/tests/indexed-types/should_compile/T4484.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies, EmptyDataDecls, GADTs #-} module T4484 where diff --git a/testsuite/tests/indexed-types/should_compile/T5591a.hs b/testsuite/tests/indexed-types/should_compile/T5591a.hs index 9c1a2c7e5175..5d9243d832dd 100644 --- a/testsuite/tests/indexed-types/should_compile/T5591a.hs +++ b/testsuite/tests/indexed-types/should_compile/T5591a.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE GADTs, TypeOperators, TypeFamilies, ScopedTypeVariables #-} module T5591a where diff --git a/testsuite/tests/indexed-types/should_compile/T8002.hs b/testsuite/tests/indexed-types/should_compile/T8002.hs index d90a502b05b4..7ca74e2ddf17 100644 --- a/testsuite/tests/indexed-types/should_compile/T8002.hs +++ b/testsuite/tests/indexed-types/should_compile/T8002.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies #-} module T8002 where diff --git a/testsuite/tests/indexed-types/should_compile/T8002a.hs b/testsuite/tests/indexed-types/should_compile/T8002a.hs index 98ac39e55f7a..59b4312d4e49 100644 --- a/testsuite/tests/indexed-types/should_compile/T8002a.hs +++ b/testsuite/tests/indexed-types/should_compile/T8002a.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE UndecidableInstances #-} {-# LANGUAGE TypeFamilies #-} diff --git a/testsuite/tests/indexed-types/should_compile/T8002b.hs b/testsuite/tests/indexed-types/should_compile/T8002b.hs index 073f930d5923..8c965a44af23 100644 --- a/testsuite/tests/indexed-types/should_compile/T8002b.hs +++ b/testsuite/tests/indexed-types/should_compile/T8002b.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies #-} module T8002b where diff --git a/testsuite/tests/indexed-types/should_compile/T8500.hs b/testsuite/tests/indexed-types/should_compile/T8500.hs index 5e8f09004f7d..abb3eba5bf58 100644 --- a/testsuite/tests/indexed-types/should_compile/T8500.hs +++ b/testsuite/tests/indexed-types/should_compile/T8500.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies #-} module T8500 where diff --git a/testsuite/tests/indexed-types/should_compile/T8500a.hs b/testsuite/tests/indexed-types/should_compile/T8500a.hs index f4f97b97a682..26dbbcbb121b 100644 --- a/testsuite/tests/indexed-types/should_compile/T8500a.hs +++ b/testsuite/tests/indexed-types/should_compile/T8500a.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies #-} module T8500a where diff --git a/testsuite/tests/indexed-types/should_compile/T9840.hs b/testsuite/tests/indexed-types/should_compile/T9840.hs index 0dc96bb9c7b6..98df2a00a12c 100644 --- a/testsuite/tests/indexed-types/should_compile/T9840.hs +++ b/testsuite/tests/indexed-types/should_compile/T9840.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies #-} module T9840 where diff --git a/testsuite/tests/indexed-types/should_compile/T9840.hs-boot b/testsuite/tests/indexed-types/should_compile/T9840.hs-boot index b60a8db0acbb..ff3001944cd9 100644 --- a/testsuite/tests/indexed-types/should_compile/T9840.hs-boot +++ b/testsuite/tests/indexed-types/should_compile/T9840.hs-boot @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies #-} module T9840 where diff --git a/testsuite/tests/indexed-types/should_compile/T9840a.hs b/testsuite/tests/indexed-types/should_compile/T9840a.hs index dab6e044f505..8741a2757923 100644 --- a/testsuite/tests/indexed-types/should_compile/T9840a.hs +++ b/testsuite/tests/indexed-types/should_compile/T9840a.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies #-} module T9840a where diff --git a/testsuite/tests/indexed-types/should_fail/ClosedFam3.hs b/testsuite/tests/indexed-types/should_fail/ClosedFam3.hs index 3dd140b615b3..5d0366446d0a 100644 --- a/testsuite/tests/indexed-types/should_fail/ClosedFam3.hs +++ b/testsuite/tests/indexed-types/should_fail/ClosedFam3.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies #-} module ClosedFam3 where diff --git a/testsuite/tests/indexed-types/should_fail/ClosedFam3.hs-boot b/testsuite/tests/indexed-types/should_fail/ClosedFam3.hs-boot index 5a10841ba485..7b72a0276a99 100644 --- a/testsuite/tests/indexed-types/should_fail/ClosedFam3.hs-boot +++ b/testsuite/tests/indexed-types/should_fail/ClosedFam3.hs-boot @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies, PolyKinds #-} module ClosedFam3 where diff --git a/testsuite/tests/indexed-types/should_fail/ClosedFam3.stderr b/testsuite/tests/indexed-types/should_fail/ClosedFam3.stderr index f0a5614560ab..28190937a49b 100644 --- a/testsuite/tests/indexed-types/should_fail/ClosedFam3.stderr +++ b/testsuite/tests/indexed-types/should_fail/ClosedFam3.stderr @@ -1,5 +1,5 @@ -ClosedFam3.hs-boot:7:1: error: +ClosedFam3.hs-boot:8:1: error: Type constructor ‘Foo’ has conflicting definitions in the module and its hs-boot file Main module: type Foo :: * -> * @@ -10,7 +10,7 @@ ClosedFam3.hs-boot:7:1: error: type family Foo a where Foo Int = Bool -ClosedFam3.hs-boot:10:1: error: +ClosedFam3.hs-boot:11:1: error: Type constructor ‘Bar’ has conflicting definitions in the module and its hs-boot file Main module: type Bar :: * -> * @@ -22,7 +22,7 @@ ClosedFam3.hs-boot:10:1: error: Bar Int = Bool Bar Double = Char -ClosedFam3.hs-boot:14:1: error: +ClosedFam3.hs-boot:15:1: error: Type constructor ‘Baz’ has conflicting definitions in the module and its hs-boot file Main module: type Baz :: * -> * diff --git a/testsuite/tests/indexed-types/should_fail/ExplicitForAllFams4a.hs b/testsuite/tests/indexed-types/should_fail/ExplicitForAllFams4a.hs index f99e884161a9..336ee7c4b350 100644 --- a/testsuite/tests/indexed-types/should_fail/ExplicitForAllFams4a.hs +++ b/testsuite/tests/indexed-types/should_fail/ExplicitForAllFams4a.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE ExplicitForAll #-} {-# LANGUAGE TypeFamilies #-} diff --git a/testsuite/tests/indexed-types/should_fail/ExplicitForAllFams4a.stderr b/testsuite/tests/indexed-types/should_fail/ExplicitForAllFams4a.stderr index 776ee19592d9..a0d74082100d 100644 --- a/testsuite/tests/indexed-types/should_fail/ExplicitForAllFams4a.stderr +++ b/testsuite/tests/indexed-types/should_fail/ExplicitForAllFams4a.stderr @@ -1,11 +1,11 @@ -ExplicitForAllFams4a.hs:7:12: error: +ExplicitForAllFams4a.hs:8:12: error: • Type variable ‘b’ is bound by a forall, but not used in the family instance • In the equations for closed type family ‘H’ In the type family declaration for ‘H’ -ExplicitForAllFams4a.hs:8:10: error: +ExplicitForAllFams4a.hs:9:10: error: • Type variable ‘b’ is mentioned in the RHS, but not bound on the LHS of the family instance • In the equations for closed type family ‘H’ diff --git a/testsuite/tests/indexed-types/should_fail/ExplicitForAllFams4b.hs b/testsuite/tests/indexed-types/should_fail/ExplicitForAllFams4b.hs index c488f45a659f..f8187e587827 100644 --- a/testsuite/tests/indexed-types/should_fail/ExplicitForAllFams4b.hs +++ b/testsuite/tests/indexed-types/should_fail/ExplicitForAllFams4b.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE ExplicitForAll #-} {-# LANGUAGE TypeFamilies #-} diff --git a/testsuite/tests/indexed-types/should_fail/ExplicitForAllFams4b.stderr b/testsuite/tests/indexed-types/should_fail/ExplicitForAllFams4b.stderr index ca0e33c5ff4c..7d8bd872edd3 100644 --- a/testsuite/tests/indexed-types/should_fail/ExplicitForAllFams4b.stderr +++ b/testsuite/tests/indexed-types/should_fail/ExplicitForAllFams4b.stderr @@ -1,82 +1,82 @@ -ExplicitForAllFams4b.hs:7:24: error: +ExplicitForAllFams4b.hs:8:24: error: • Type variable ‘b’ is bound by a forall, but not used in the family instance • In the type instance declaration for ‘J’ -ExplicitForAllFams4b.hs:7:27: error: +ExplicitForAllFams4b.hs:8:27: error: Conflicting family instance declarations: - J [a] = Float -- Defined at ExplicitForAllFams4b.hs:7:27 - J _ = Maybe b -- Defined at ExplicitForAllFams4b.hs:8:27 + J [a] = Float -- Defined at ExplicitForAllFams4b.hs:8:27 + J _ = Maybe b -- Defined at ExplicitForAllFams4b.hs:9:27 -ExplicitForAllFams4b.hs:8:22: error: +ExplicitForAllFams4b.hs:9:22: error: • Type variable ‘b’ is mentioned in the RHS, but not bound on the LHS of the family instance • In the type instance declaration for ‘J’ -ExplicitForAllFams4b.hs:11:24: error: +ExplicitForAllFams4b.hs:12:24: error: • Type variable ‘b’ is mentioned in the RHS, but not bound on the LHS of the family instance • In the data instance declaration for ‘K’ -ExplicitForAllFams4b.hs:11:27: error: +ExplicitForAllFams4b.hs:12:27: error: Conflicting family instance declarations: - K (a, Bool) -- Defined at ExplicitForAllFams4b.hs:11:27 - K _ -- Defined at ExplicitForAllFams4b.hs:12:27 + K (a, Bool) -- Defined at ExplicitForAllFams4b.hs:12:27 + K _ -- Defined at ExplicitForAllFams4b.hs:13:27 -ExplicitForAllFams4b.hs:12:22: error: +ExplicitForAllFams4b.hs:13:22: error: • Type variable ‘b’ is mentioned in the RHS, but not bound on the LHS of the family instance • In the data instance declaration for ‘K’ -ExplicitForAllFams4b.hs:15:27: error: +ExplicitForAllFams4b.hs:16:27: error: • Type variable ‘b’ is mentioned in the RHS, but not bound on the LHS of the family instance • In the newtype instance declaration for ‘L’ -ExplicitForAllFams4b.hs:15:30: error: +ExplicitForAllFams4b.hs:16:30: error: Conflicting family instance declarations: - L (a, Bool) -- Defined at ExplicitForAllFams4b.hs:15:30 - L _ -- Defined at ExplicitForAllFams4b.hs:16:30 + L (a, Bool) -- Defined at ExplicitForAllFams4b.hs:16:30 + L _ -- Defined at ExplicitForAllFams4b.hs:17:30 -ExplicitForAllFams4b.hs:16:25: error: +ExplicitForAllFams4b.hs:17:25: error: • Type variable ‘b’ is mentioned in the RHS, but not bound on the LHS of the family instance • In the newtype instance declaration for ‘L’ -ExplicitForAllFams4b.hs:23:3: error: +ExplicitForAllFams4b.hs:24:3: error: • Type indexes must match class instance head Expected: CT Int _ Actual: CT [a] (a, a) • In the type instance declaration for ‘CT’ In the instance declaration for ‘C Int’ -ExplicitForAllFams4b.hs:23:17: error: +ExplicitForAllFams4b.hs:24:17: error: • Type variable ‘b’ is bound by a forall, but not used in the family instance • In the type instance declaration for ‘CT’ In the instance declaration for ‘C Int’ -ExplicitForAllFams4b.hs:24:15: error: +ExplicitForAllFams4b.hs:25:15: error: • Type variable ‘b’ is mentioned in the RHS, but not bound on the LHS of the family instance • In the type instance declaration for ‘CT’ In the instance declaration for ‘C Int’ -ExplicitForAllFams4b.hs:26:3: error: +ExplicitForAllFams4b.hs:27:3: error: • Type indexes must match class instance head Expected: CD Int _ Actual: CD [a] (a, a) • In the data instance declaration for ‘CD’ In the instance declaration for ‘C Int’ -ExplicitForAllFams4b.hs:26:17: error: +ExplicitForAllFams4b.hs:27:17: error: • Type variable ‘b’ is mentioned in the RHS, but not bound on the LHS of the family instance • In the data instance declaration for ‘CD’ In the instance declaration for ‘C Int’ -ExplicitForAllFams4b.hs:27:15: error: +ExplicitForAllFams4b.hs:28:15: error: • Type variable ‘b’ is mentioned in the RHS, but not bound on the LHS of the family instance • In the data instance declaration for ‘CD’ diff --git a/testsuite/tests/indexed-types/should_fail/SimpleFail15.hs b/testsuite/tests/indexed-types/should_fail/SimpleFail15.hs index 586403937b1e..6cc10e05296d 100644 --- a/testsuite/tests/indexed-types/should_fail/SimpleFail15.hs +++ b/testsuite/tests/indexed-types/should_fail/SimpleFail15.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies #-} module ShouldFail where diff --git a/testsuite/tests/indexed-types/should_fail/SimpleFail15.stderr b/testsuite/tests/indexed-types/should_fail/SimpleFail15.stderr index 55d0358bfc81..7119b9a8a9aa 100644 --- a/testsuite/tests/indexed-types/should_fail/SimpleFail15.stderr +++ b/testsuite/tests/indexed-types/should_fail/SimpleFail15.stderr @@ -1,5 +1,5 @@ -SimpleFail15.hs:5:8: error: +SimpleFail15.hs:6:8: error: • Illegal qualified type: (a ~ b) => t Perhaps you intended to use RankNTypes • In the type signature: foo :: (a, b) -> (a ~ b => t) -> (a, b) diff --git a/testsuite/tests/indexed-types/should_fail/SimpleFail4.hs b/testsuite/tests/indexed-types/should_fail/SimpleFail4.hs index 589372cd5ea8..0748856ea3e6 100644 --- a/testsuite/tests/indexed-types/should_fail/SimpleFail4.hs +++ b/testsuite/tests/indexed-types/should_fail/SimpleFail4.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies, MultiParamTypeClasses #-} module ShouldFail where diff --git a/testsuite/tests/indexed-types/should_fail/SimpleFail4.stderr b/testsuite/tests/indexed-types/should_fail/SimpleFail4.stderr index d23b24d82497..3d7947e625c7 100644 --- a/testsuite/tests/indexed-types/should_fail/SimpleFail4.stderr +++ b/testsuite/tests/indexed-types/should_fail/SimpleFail4.stderr @@ -1,5 +1,5 @@ -SimpleFail4.hs:10:3: error: +SimpleFail4.hs:11:3: error: • Illegal argument ‘Int’ in: ‘type S2 Int = ...’ The arguments to ‘S2’ must all be distinct type variables diff --git a/testsuite/tests/indexed-types/should_fail/T10899.hs b/testsuite/tests/indexed-types/should_fail/T10899.hs index cacac4a2f76b..d3cd973d6b47 100644 --- a/testsuite/tests/indexed-types/should_fail/T10899.hs +++ b/testsuite/tests/indexed-types/should_fail/T10899.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies, RankNTypes #-} module T10899 where diff --git a/testsuite/tests/indexed-types/should_fail/T10899.stderr b/testsuite/tests/indexed-types/should_fail/T10899.stderr index 0dd92ef9bf4c..ef0bd1b3f435 100644 --- a/testsuite/tests/indexed-types/should_fail/T10899.stderr +++ b/testsuite/tests/indexed-types/should_fail/T10899.stderr @@ -1,5 +1,5 @@ -T10899.hs:7:3: error: +T10899.hs:8:3: error: • Illegal polymorphic type: forall (m :: * -> *). m a • In the default type instance declaration for ‘F’ In the class declaration for ‘C’ diff --git a/testsuite/tests/indexed-types/should_fail/T12867.hs b/testsuite/tests/indexed-types/should_fail/T12867.hs index e4a39ce56eee..5b3120f51f0a 100644 --- a/testsuite/tests/indexed-types/should_fail/T12867.hs +++ b/testsuite/tests/indexed-types/should_fail/T12867.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies #-} {-# LANGUAGE ConstraintKinds #-} {-# LANGUAGE FlexibleContexts #-} diff --git a/testsuite/tests/indexed-types/should_fail/T12867.stderr b/testsuite/tests/indexed-types/should_fail/T12867.stderr index 2115e4354193..501da2090784 100644 --- a/testsuite/tests/indexed-types/should_fail/T12867.stderr +++ b/testsuite/tests/indexed-types/should_fail/T12867.stderr @@ -1,11 +1,11 @@ -T12867.hs:7:21: error: +T12867.hs:8:21: error: • Expected kind ‘k0 -> *’, but ‘TestM’ has kind ‘*’ • In the first argument of ‘Eq’, namely ‘(TestM a)’ In the type ‘(Eq (TestM a))’ In the type declaration for ‘Test2’ -T12867.hs:9:1: error: +T12867.hs:10:1: error: • The associated type ‘TestM’ mentions none of the type or kind variables of the class ‘Test a’ • In the class declaration for ‘Test’ diff --git a/testsuite/tests/indexed-types/should_fail/T14246.hs b/testsuite/tests/indexed-types/should_fail/T14246.hs index 6ae8760c84a5..09840f6d9e34 100644 --- a/testsuite/tests/indexed-types/should_fail/T14246.hs +++ b/testsuite/tests/indexed-types/should_fail/T14246.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE RankNTypes, GADTs, TypeOperators, PolyKinds, DataKinds, TypeFamilies, AllowAmbiguousTypes, UndecidableInstances, TypeInType #-} module T14246 where diff --git a/testsuite/tests/indexed-types/should_fail/T14246.stderr b/testsuite/tests/indexed-types/should_fail/T14246.stderr index d6bfde7b5b27..a41f73efa580 100644 --- a/testsuite/tests/indexed-types/should_fail/T14246.stderr +++ b/testsuite/tests/indexed-types/should_fail/T14246.stderr @@ -1,10 +1,10 @@ -T14246.hs:18:5: error: +T14246.hs:19:5: error: • Illegal polymorphic type: forall (t :: v). f t • In the equations for closed type family ‘KLN’ In the type family declaration for ‘KLN’ -T14246.hs:22:27: error: +T14246.hs:23:27: error: • Couldn't match kind: 'S (KLN (f t)) with: KLN f Expected kind ‘Vect (KLN f) L’, @@ -13,7 +13,7 @@ T14246.hs:22:27: error: ‘(Cons (Label (t :: v)) l)’ In the type family declaration for ‘Reveal’ -T14246.hs:22:67: error: +T14246.hs:23:67: error: • Couldn't match kind ‘*’ with ‘L’ Expected kind ‘Vect (KLN (f t)) L’, but ‘l’ has kind ‘Vect (KLN (f t)) (*)’ @@ -21,7 +21,7 @@ T14246.hs:22:67: error: In the type ‘Reveal (f t) l’ In the type family declaration for ‘Reveal’ -T14246.hs:23:24: error: +T14246.hs:24:24: error: • Couldn't match kind ‘'Z’ with ‘KLN a’ Expected kind ‘Vect (KLN a) L’, but ‘Nil’ has kind ‘Vect 'Z L’ • In the second argument of ‘Reveal’, namely ‘Nil’ diff --git a/testsuite/tests/indexed-types/should_fail/T14887.hs b/testsuite/tests/indexed-types/should_fail/T14887.hs index 63fbbd39438f..e0ede0150097 100644 --- a/testsuite/tests/indexed-types/should_fail/T14887.hs +++ b/testsuite/tests/indexed-types/should_fail/T14887.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies #-} {-# LANGUAGE TypeInType #-} {-# LANGUAGE TypeOperators #-} diff --git a/testsuite/tests/indexed-types/should_fail/T14887.stderr b/testsuite/tests/indexed-types/should_fail/T14887.stderr index 6b5c57977e21..9e55af541f22 100644 --- a/testsuite/tests/indexed-types/should_fail/T14887.stderr +++ b/testsuite/tests/indexed-types/should_fail/T14887.stderr @@ -1,5 +1,5 @@ -T14887.hs:13:1: error: +T14887.hs:14:1: error: • The kind of ‘Foo2’ is ill-scoped Inferred kind: Foo2 :: forall (a :: k). forall k -> (a :~: a) -> * NB: Specified variables (namely: (a :: k)) always come first diff --git a/testsuite/tests/indexed-types/should_fail/T16356_Fail3.hs b/testsuite/tests/indexed-types/should_fail/T16356_Fail3.hs index da59f5399d7b..709567daf801 100644 --- a/testsuite/tests/indexed-types/should_fail/T16356_Fail3.hs +++ b/testsuite/tests/indexed-types/should_fail/T16356_Fail3.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeApplications #-} {-# LANGUAGE TypeFamilies #-} module T16356_Fail3 where diff --git a/testsuite/tests/indexed-types/should_fail/T16356_Fail3.stderr b/testsuite/tests/indexed-types/should_fail/T16356_Fail3.stderr index e8b59175f4d9..7dcc5defea37 100644 --- a/testsuite/tests/indexed-types/should_fail/T16356_Fail3.stderr +++ b/testsuite/tests/indexed-types/should_fail/T16356_Fail3.stderr @@ -1,5 +1,5 @@ -T16356_Fail3.hs:9:3: error: +T16356_Fail3.hs:10:3: error: • Cannot apply function of kind ‘* -> *’ to visible kind argument ‘Type’ • In the default type instance declaration for ‘T1’ diff --git a/testsuite/tests/indexed-types/should_fail/T18648.hs b/testsuite/tests/indexed-types/should_fail/T18648.hs index 92502b77c81a..58334681887c 100644 --- a/testsuite/tests/indexed-types/should_fail/T18648.hs +++ b/testsuite/tests/indexed-types/should_fail/T18648.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies #-} module T18648 where diff --git a/testsuite/tests/indexed-types/should_fail/T18648.stderr b/testsuite/tests/indexed-types/should_fail/T18648.stderr index 0fbb014b50ed..2682a4e22d2e 100644 --- a/testsuite/tests/indexed-types/should_fail/T18648.stderr +++ b/testsuite/tests/indexed-types/should_fail/T18648.stderr @@ -1,12 +1,12 @@ -T18648.hs:6:4: error: +T18648.hs:7:4: error: • Illegal argument ‘f a’ in: ‘type Bar1 (f a) = ...’ The arguments to ‘Bar1’ must all be distinct type variables • In the default type instance declaration for ‘Bar1’ In the class declaration for ‘Foo1’ -T18648.hs:10:4: error: +T18648.hs:11:4: error: • Illegal argument ‘Bar2 a’ in: ‘type Bar2 (Bar2 a) = ...’ The arguments to ‘Bar2’ must all be distinct type variables diff --git a/testsuite/tests/indexed-types/should_fail/T1900.hs b/testsuite/tests/indexed-types/should_fail/T1900.hs index efcfbc139133..25f7bbb261a4 100644 --- a/testsuite/tests/indexed-types/should_fail/T1900.hs +++ b/testsuite/tests/indexed-types/should_fail/T1900.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies, FlexibleContexts #-} module Class4 where diff --git a/testsuite/tests/indexed-types/should_fail/T1900.stderr b/testsuite/tests/indexed-types/should_fail/T1900.stderr index a9fb9051e80c..bb4a160d49e7 100644 --- a/testsuite/tests/indexed-types/should_fail/T1900.stderr +++ b/testsuite/tests/indexed-types/should_fail/T1900.stderr @@ -1,5 +1,5 @@ -T1900.hs:7:3: error: +T1900.hs:8:3: error: • Couldn't match type: Depend s0 with: Depend s Expected: Depend s -> Depend s diff --git a/testsuite/tests/indexed-types/should_fail/T2664.hs b/testsuite/tests/indexed-types/should_fail/T2664.hs index bda1adfa4205..5d6393371627 100644 --- a/testsuite/tests/indexed-types/should_fail/T2664.hs +++ b/testsuite/tests/indexed-types/should_fail/T2664.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE EmptyDataDecls, TypeFamilies, TypeOperators, ScopedTypeVariables #-} module Overflow where import Control.Concurrent diff --git a/testsuite/tests/indexed-types/should_fail/T2664.stderr b/testsuite/tests/indexed-types/should_fail/T2664.stderr index deaffc82ddc9..155fe0e03b5f 100644 --- a/testsuite/tests/indexed-types/should_fail/T2664.stderr +++ b/testsuite/tests/indexed-types/should_fail/T2664.stderr @@ -1,22 +1,22 @@ -T2664.hs:31:52: error: +T2664.hs:32:52: error: • Could not deduce: b ~ a arising from a use of ‘newPChan’ from the context: ((a :*: b) ~ Dual c, c ~ Dual (a :*: b)) bound by the type signature for: newPChan :: forall c. ((a :*: b) ~ Dual c, c ~ Dual (a :*: b)) => IO (PChan (a :*: b), PChan c) - at T2664.hs:23:5-12 + at T2664.hs:24:5-12 ‘b’ is a rigid type variable bound by the instance declaration - at T2664.hs:22:10-52 + at T2664.hs:23:10-52 ‘a’ is a rigid type variable bound by the instance declaration - at T2664.hs:22:10-52 + at T2664.hs:23:10-52 • In the third argument of ‘pchoose’, namely ‘newPChan’ In the first argument of ‘E’, namely ‘(pchoose Right v newPChan)’ In the expression: E (pchoose Right v newPChan) (pchoose Left v newPChan) • Relevant bindings include - v :: MVar (Either (PChan a) (PChan b)) (bound at T2664.hs:24:9) - newPChan :: IO (PChan (a :*: b), PChan c) (bound at T2664.hs:23:5) + v :: MVar (Either (PChan a) (PChan b)) (bound at T2664.hs:25:9) + newPChan :: IO (PChan (a :*: b), PChan c) (bound at T2664.hs:24:5) diff --git a/testsuite/tests/indexed-types/should_fail/T2664a.hs b/testsuite/tests/indexed-types/should_fail/T2664a.hs index b7a3033723c5..0b0835db332f 100644 --- a/testsuite/tests/indexed-types/should_fail/T2664a.hs +++ b/testsuite/tests/indexed-types/should_fail/T2664a.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE EmptyDataDecls, TypeFamilies, TypeOperators, ScopedTypeVariables #-} module Overflow where import Control.Concurrent diff --git a/testsuite/tests/indexed-types/should_fail/T2888.hs b/testsuite/tests/indexed-types/should_fail/T2888.hs index 169eebb474d7..f5a33e8dc5df 100644 --- a/testsuite/tests/indexed-types/should_fail/T2888.hs +++ b/testsuite/tests/indexed-types/should_fail/T2888.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies #-} -- Test for no type indices diff --git a/testsuite/tests/indexed-types/should_fail/T2888.stderr b/testsuite/tests/indexed-types/should_fail/T2888.stderr index 3d2c221703cb..068eab1d3d36 100644 --- a/testsuite/tests/indexed-types/should_fail/T2888.stderr +++ b/testsuite/tests/indexed-types/should_fail/T2888.stderr @@ -1,5 +1,5 @@ -T2888.hs:6:1: - The associated type ‘D’ - mentions none of the type or kind variables of the class ‘C w’ - In the class declaration for ‘C’ +T2888.hs:7:1: error: + • The associated type ‘D’ + mentions none of the type or kind variables of the class ‘C w’ + • In the class declaration for ‘C’ diff --git a/testsuite/tests/indexed-types/should_fail/T4174.hs b/testsuite/tests/indexed-types/should_fail/T4174.hs index a4f105ff86fb..93805d2d69e1 100644 --- a/testsuite/tests/indexed-types/should_fail/T4174.hs +++ b/testsuite/tests/indexed-types/should_fail/T4174.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies, TypeOperators, EmptyDataDecls #-} module T4174 where diff --git a/testsuite/tests/indexed-types/should_fail/T4174.stderr b/testsuite/tests/indexed-types/should_fail/T4174.stderr index 396fab9469cc..14156deaf0f1 100644 --- a/testsuite/tests/indexed-types/should_fail/T4174.stderr +++ b/testsuite/tests/indexed-types/should_fail/T4174.stderr @@ -1,5 +1,5 @@ -T4174.hs:44:12: error: +T4174.hs:45:12: error: • Couldn't match type ‘a’ with ‘SmStep’ Expected: m (Field (Way (GHC6'8 minor) n t p) a b) Actual: m (Field (WayOf m) SmStep RtsSpinLock) @@ -8,9 +8,9 @@ T4174.hs:44:12: error: testcase :: forall (m :: * -> *) minor n t p a b. Monad m => m (Field (Way (GHC6'8 minor) n t p) a b) - at T4174.hs:43:1-63 + at T4174.hs:44:1-63 • In the expression: sync_large_objects In an equation for ‘testcase’: testcase = sync_large_objects • Relevant bindings include testcase :: m (Field (Way (GHC6'8 minor) n t p) a b) - (bound at T4174.hs:44:1) + (bound at T4174.hs:45:1) diff --git a/testsuite/tests/indexed-types/should_fail/T4246.hs b/testsuite/tests/indexed-types/should_fail/T4246.hs index ad280583abe3..fb86a5d37bcb 100644 --- a/testsuite/tests/indexed-types/should_fail/T4246.hs +++ b/testsuite/tests/indexed-types/should_fail/T4246.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies, FlexibleInstances #-} module T4246 where diff --git a/testsuite/tests/indexed-types/should_fail/T4246.stderr b/testsuite/tests/indexed-types/should_fail/T4246.stderr index b653f9a05287..f2bf56b214b9 100644 --- a/testsuite/tests/indexed-types/should_fail/T4246.stderr +++ b/testsuite/tests/indexed-types/should_fail/T4246.stderr @@ -1,10 +1,10 @@ -T4246.hs:8:9: +T4246.hs:9:9: error: Conflicting family instance declarations: - F a = a -- Defined at T4246.hs:8:9 - F Int = Bool -- Defined at T4246.hs:11:9 + F a = a -- Defined at T4246.hs:9:9 + F Int = Bool -- Defined at T4246.hs:12:9 -T4246.hs:14:15: +T4246.hs:15:15: error: Conflicting family instance declarations: - G Int = Int -- Defined at T4246.hs:14:15 - G Int = Bool -- Defined at T4246.hs:15:15 + G Int = Int -- Defined at T4246.hs:15:15 + G Int = Bool -- Defined at T4246.hs:16:15 diff --git a/testsuite/tests/indexed-types/should_fail/T4485.hs b/testsuite/tests/indexed-types/should_fail/T4485.hs index 060e8571b53a..c314018cc5a9 100644 --- a/testsuite/tests/indexed-types/should_fail/T4485.hs +++ b/testsuite/tests/indexed-types/should_fail/T4485.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} -- The behavior of type-inference and OverlappingInstances has changed -- between GHC 6.12 and GHC 7.0 such that the following code -- type-checks under 6.12, but not 7.0rc2. I assume this change has diff --git a/testsuite/tests/indexed-types/should_fail/T4485.stderr b/testsuite/tests/indexed-types/should_fail/T4485.stderr index bdf5218b42d8..a2b92b6361f1 100644 --- a/testsuite/tests/indexed-types/should_fail/T4485.stderr +++ b/testsuite/tests/indexed-types/should_fail/T4485.stderr @@ -1,15 +1,15 @@ -T4485.hs:50:15: error: +T4485.hs:51:15: error: • Overlapping instances for EmbedAsChild (IdentityT IO) (XMLGenT m0 (XML m0)) arising from a use of ‘asChild’ Matching instances: instance [overlapping] (EmbedAsChild m c, m1 ~ m) => EmbedAsChild m (XMLGenT m1 c) - -- Defined at T4485.hs:28:30 + -- Defined at T4485.hs:29:30 instance [overlapping] EmbedAsChild (IdentityT IO) (XMLGenT Identity ()) - -- Defined at T4485.hs:45:30 + -- Defined at T4485.hs:46:30 (The choice depends on the instantiation of ‘m0’ To pick the first instance above, use IncoherentInstances when compiling the other instance declarations) @@ -18,12 +18,12 @@ T4485.hs:50:15: error: In an equation for ‘asChild’: asChild b = asChild $ (genElement "foo") -T4485.hs:50:26: error: +T4485.hs:51:26: error: • Ambiguous type variable ‘m0’ arising from a use of ‘genElement’ prevents the constraint ‘(XMLGen m0)’ from being solved. Probable fix: use a type annotation to specify what ‘m0’ should be. These potential instance exist: - instance XMLGen (IdentityT m) -- Defined at T4485.hs:37:10 + instance XMLGen (IdentityT m) -- Defined at T4485.hs:38:10 • In the second argument of ‘($)’, namely ‘(genElement "foo")’ In the expression: asChild $ (genElement "foo") In an equation for ‘asChild’: diff --git a/testsuite/tests/indexed-types/should_fail/T5439.hs b/testsuite/tests/indexed-types/should_fail/T5439.hs index dfcd399b4fb3..d5be550de553 100644 --- a/testsuite/tests/indexed-types/should_fail/T5439.hs +++ b/testsuite/tests/indexed-types/should_fail/T5439.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE UnicodeSyntax #-} {-# LANGUAGE DeriveDataTypeable #-} {-# LANGUAGE EmptyDataDecls #-} diff --git a/testsuite/tests/indexed-types/should_fail/T5439.stderr b/testsuite/tests/indexed-types/should_fail/T5439.stderr index c7f230654e80..fb38d71112c9 100644 --- a/testsuite/tests/indexed-types/should_fail/T5439.stderr +++ b/testsuite/tests/indexed-types/should_fail/T5439.stderr @@ -1,5 +1,5 @@ -T5439.hs:82:33: error: +T5439.hs:83:33: error: • Couldn't match expected type: Attempt (HElemOf rs) with actual type: Attempt (HHead (HDrop n0 l0)) -> Attempt (HElemOf l0) @@ -13,15 +13,15 @@ T5439.hs:82:33: error: return $ c || not first • Relevant bindings include register :: Bool -> Peano n -> WaitOps (HDrop n rs) -> IO Bool - (bound at T5439.hs:64:9) + (bound at T5439.hs:65:9) ev :: f (Attempt (WaitOpResult (WaitOps rs))) - (bound at T5439.hs:61:22) - ops :: WaitOps rs (bound at T5439.hs:61:18) + (bound at T5439.hs:62:22) + ops :: WaitOps rs (bound at T5439.hs:62:18) registerWaitOp :: WaitOps rs -> f (Attempt (WaitOpResult (WaitOps rs))) -> IO Bool - (bound at T5439.hs:61:3) + (bound at T5439.hs:62:3) -T5439.hs:82:39: error: +T5439.hs:83:39: error: • Couldn't match expected type: Peano n0 with actual type: Attempt α0 • In the second argument of ‘($)’, namely diff --git a/testsuite/tests/indexed-types/should_fail/T9167.hs b/testsuite/tests/indexed-types/should_fail/T9167.hs index 2d2f555011b8..462959d22f3d 100644 --- a/testsuite/tests/indexed-types/should_fail/T9167.hs +++ b/testsuite/tests/indexed-types/should_fail/T9167.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies #-} module T9167 where diff --git a/testsuite/tests/indexed-types/should_fail/T9167.stderr b/testsuite/tests/indexed-types/should_fail/T9167.stderr index 2c296793dcef..8b08e4fddded 100644 --- a/testsuite/tests/indexed-types/should_fail/T9167.stderr +++ b/testsuite/tests/indexed-types/should_fail/T9167.stderr @@ -1,5 +1,5 @@ -T9167.hs:5:1: error: +T9167.hs:6:1: error: • The associated type ‘F b’ mentions none of the type or kind variables of the class ‘C a’ • In the class declaration for ‘C’ diff --git a/testsuite/tests/llvm/should_compile/T11649.hs b/testsuite/tests/llvm/should_compile/T11649.hs index 9d09c3a12071..eb0c01bd904a 100644 --- a/testsuite/tests/llvm/should_compile/T11649.hs +++ b/testsuite/tests/llvm/should_compile/T11649.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE NoImplicitPrelude #-} module Test where import GHC.Base diff --git a/testsuite/tests/llvm/should_compile/T5681.hs b/testsuite/tests/llvm/should_compile/T5681.hs index 1ce84b6ccb98..d1c073a328ff 100644 --- a/testsuite/tests/llvm/should_compile/T5681.hs +++ b/testsuite/tests/llvm/should_compile/T5681.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE MagicHash, UnboxedTuples #-} -- Test case for #5681 module Main where diff --git a/testsuite/tests/llvm/should_compile/T8131b.hs b/testsuite/tests/llvm/should_compile/T8131b.hs index b9bc1f6184c4..e57d6dcf77d7 100644 --- a/testsuite/tests/llvm/should_compile/T8131b.hs +++ b/testsuite/tests/llvm/should_compile/T8131b.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE MagicHash, UnboxedTuples #-} import GHC.Prim import GHC.IO diff --git a/testsuite/tests/module/mod103.hs b/testsuite/tests/module/mod103.hs index ccd6ddfd0d6a..7d713e8f7977 100644 --- a/testsuite/tests/module/mod103.hs +++ b/testsuite/tests/module/mod103.hs @@ -1,3 +1,5 @@ +{-# LANGUAGE Haskell2010 #-} +{-# LANGUAGE NondecreasingIndentation #-} -- !!! Layout rule extension (restricting empty do's). module Foo where diff --git a/testsuite/tests/module/mod182.hs b/testsuite/tests/module/mod182.hs index 379fb3849fc3..69290a910404 100644 --- a/testsuite/tests/module/mod182.hs +++ b/testsuite/tests/module/mod182.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} -- If 'ImportQualifiedPost' is not enabled 'qualified' can not appear in -- postpositive position. diff --git a/testsuite/tests/module/mod182.stderr b/testsuite/tests/module/mod182.stderr index 290929822005..51886000de7c 100644 --- a/testsuite/tests/module/mod182.stderr +++ b/testsuite/tests/module/mod182.stderr @@ -1,3 +1,4 @@ -mod182.hs:5:16: error: - Found ‘qualified’ in postpositive position. + +mod182.hs:6:16: error: + Found ‘qualified’ in postpositive position. To allow this, enable language extension 'ImportQualifiedPost' diff --git a/testsuite/tests/module/mod39.hs b/testsuite/tests/module/mod39.hs index 477e0a3854c0..660cd11469c6 100644 --- a/testsuite/tests/module/mod39.hs +++ b/testsuite/tests/module/mod39.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} -- !!! Class variable constraints on member funs module M where class C a where f :: Eq a => a diff --git a/testsuite/tests/module/mod39.stderr b/testsuite/tests/module/mod39.stderr index 95aaddbac5e4..d54a231152dd 100644 --- a/testsuite/tests/module/mod39.stderr +++ b/testsuite/tests/module/mod39.stderr @@ -1,5 +1,5 @@ -mod39.hs:3:17: error: +mod39.hs:4:17: error: • Constraint ‘Eq a’ in the type of ‘f’ constrains only the class type variables Enable ConstrainedClassMethods to allow it diff --git a/testsuite/tests/module/mod41.hs b/testsuite/tests/module/mod41.hs index a1ac924242bf..a290753a770d 100644 --- a/testsuite/tests/module/mod41.hs +++ b/testsuite/tests/module/mod41.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} -- !!! Repeated variable in instance predicate module M where instance Eq a => Eq (Either a a) diff --git a/testsuite/tests/module/mod41.stderr b/testsuite/tests/module/mod41.stderr index 9962da3716a1..d1253821cd46 100644 --- a/testsuite/tests/module/mod41.stderr +++ b/testsuite/tests/module/mod41.stderr @@ -1,8 +1,8 @@ -mod41.hs:3:18: - Illegal instance declaration for ‘Eq (Either a a)’ - (All instance types must be of the form (T a1 ... an) - where a1 ... an are *distinct type variables*, - and each type variable appears at most once in the instance head. - Use FlexibleInstances if you want to disable this.) - In the instance declaration for ‘Eq (Either a a)’ +mod41.hs:4:18: error: + • Illegal instance declaration for ‘Eq (Either a a)’ + (All instance types must be of the form (T a1 ... an) + where a1 ... an are *distinct type variables*, + and each type variable appears at most once in the instance head. + Use FlexibleInstances if you want to disable this.) + • In the instance declaration for ‘Eq (Either a a)’ diff --git a/testsuite/tests/module/mod42.hs b/testsuite/tests/module/mod42.hs index 9828d8b64247..bcab1f976650 100644 --- a/testsuite/tests/module/mod42.hs +++ b/testsuite/tests/module/mod42.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} -- !!! Not "simple type" in instance module M where instance Eq a diff --git a/testsuite/tests/module/mod42.stderr b/testsuite/tests/module/mod42.stderr index 03e7f8cdcef1..45d649177a90 100644 --- a/testsuite/tests/module/mod42.stderr +++ b/testsuite/tests/module/mod42.stderr @@ -1,8 +1,8 @@ -mod42.hs:3:10: - Illegal instance declaration for ‘Eq a’ - (All instance types must be of the form (T a1 ... an) - where a1 ... an are *distinct type variables*, - and each type variable appears at most once in the instance head. - Use FlexibleInstances if you want to disable this.) - In the instance declaration for ‘Eq a’ +mod42.hs:4:10: error: + • Illegal instance declaration for ‘Eq a’ + (All instance types must be of the form (T a1 ... an) + where a1 ... an are *distinct type variables*, + and each type variable appears at most once in the instance head. + Use FlexibleInstances if you want to disable this.) + • In the instance declaration for ‘Eq a’ diff --git a/testsuite/tests/module/mod43.hs b/testsuite/tests/module/mod43.hs index 085382f8b008..0017df031c22 100644 --- a/testsuite/tests/module/mod43.hs +++ b/testsuite/tests/module/mod43.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} -- !!! Type synonym in instance module M where instance Eq String diff --git a/testsuite/tests/module/mod43.stderr b/testsuite/tests/module/mod43.stderr index d73c51e4a4e8..f63e09207b37 100644 --- a/testsuite/tests/module/mod43.stderr +++ b/testsuite/tests/module/mod43.stderr @@ -1,7 +1,7 @@ -mod43.hs:3:10: - Illegal instance declaration for ‘Eq String’ - (All instance types must be of the form (T t1 ... tn) - where T is not a synonym. - Use TypeSynonymInstances if you want to disable this.) - In the instance declaration for ‘Eq String’ +mod43.hs:4:10: error: + • Illegal instance declaration for ‘Eq String’ + (All instance types must be of the form (T t1 ... tn) + where T is not a synonym. + Use TypeSynonymInstances if you want to disable this.) + • In the instance declaration for ‘Eq String’ diff --git a/testsuite/tests/module/mod45.hs b/testsuite/tests/module/mod45.hs index 03a1bc32ba59..a49f7da619e1 100644 --- a/testsuite/tests/module/mod45.hs +++ b/testsuite/tests/module/mod45.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} -- !!! Type sigs in instance decl module M where data T = T Int diff --git a/testsuite/tests/module/mod45.stderr b/testsuite/tests/module/mod45.stderr index ac8f21b54c16..8f62bad0e3d5 100644 --- a/testsuite/tests/module/mod45.stderr +++ b/testsuite/tests/module/mod45.stderr @@ -1,6 +1,6 @@ -mod45.hs:5:11: - Illegal type signature in instance declaration: - (==) :: T -> T -> Bool - (Use InstanceSigs to allow this) - In the instance declaration for ‘Eq T’ +mod45.hs:6:11: error: + • Illegal type signature in instance declaration: + (==) :: T -> T -> Bool + (Use InstanceSigs to allow this) + • In the instance declaration for ‘Eq T’ diff --git a/testsuite/tests/parser/should_compile/DumpParsedAst.hs b/testsuite/tests/parser/should_compile/DumpParsedAst.hs index f2bf43332419..15b37b683cd6 100644 --- a/testsuite/tests/parser/should_compile/DumpParsedAst.hs +++ b/testsuite/tests/parser/should_compile/DumpParsedAst.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE DataKinds, PolyKinds, TypeOperators, TypeFamilies , TypeApplications, TypeInType #-} diff --git a/testsuite/tests/parser/should_compile/DumpParsedAst.stderr b/testsuite/tests/parser/should_compile/DumpParsedAst.stderr index f19d67a1b205..640adcb50bbc 100644 --- a/testsuite/tests/parser/should_compile/DumpParsedAst.stderr +++ b/testsuite/tests/parser/should_compile/DumpParsedAst.stderr @@ -6,14 +6,14 @@ (VirtualBraces (1)) (Just - ({ DumpParsedAst.hs:4:8-20 } + ({ DumpParsedAst.hs:5:8-20 } {ModuleName: DumpParsedAst})) (Nothing) - [({ DumpParsedAst.hs:5:1-16 } + [({ DumpParsedAst.hs:6:1-16 } (ImportDecl (NoExtField) (NoSourceText) - ({ DumpParsedAst.hs:5:8-16 } + ({ DumpParsedAst.hs:6:8-16 } {ModuleName: Data.Kind}) (Nothing) (NotBoot) @@ -22,12 +22,12 @@ (False) (Nothing) (Nothing)))] - [({ DumpParsedAst.hs:7:1-30 } + [({ DumpParsedAst.hs:8:1-30 } (TyClD (NoExtField) (DataDecl (NoExtField) - ({ DumpParsedAst.hs:7:6-10 } + ({ DumpParsedAst.hs:8:6-10 } (Unqual {OccName: Peano})) (HsQTvs @@ -40,10 +40,10 @@ (Nothing) (Nothing) (Nothing) - [({ DumpParsedAst.hs:7:14-17 } + [({ DumpParsedAst.hs:8:14-17 } (ConDeclH98 (NoExtField) - ({ DumpParsedAst.hs:7:14-17 } + ({ DumpParsedAst.hs:8:14-17 } (Unqual {OccName: Zero})) ({ <no location info> } @@ -54,10 +54,10 @@ [] []) (Nothing))) - ,({ DumpParsedAst.hs:7:21-30 } + ,({ DumpParsedAst.hs:8:21-30 } (ConDeclH98 (NoExtField) - ({ DumpParsedAst.hs:7:21-24 } + ({ DumpParsedAst.hs:8:21-24 } (Unqual {OccName: Succ})) ({ <no location info> } @@ -69,17 +69,17 @@ [(HsScaled (HsLinearArrow (NormalSyntax)) - ({ DumpParsedAst.hs:7:26-30 } + ({ DumpParsedAst.hs:8:26-30 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpParsedAst.hs:7:26-30 } + ({ DumpParsedAst.hs:8:26-30 } (Unqual {OccName: Peano})))))]) (Nothing)))] ({ <no location info> } []))))) - ,({ DumpParsedAst.hs:9:1-39 } + ,({ DumpParsedAst.hs:10:1-39 } (TyClD (NoExtField) (FamDecl @@ -88,154 +88,154 @@ (NoExtField) (ClosedTypeFamily (Just - [({ DumpParsedAst.hs:10:3-36 } + [({ DumpParsedAst.hs:11:3-36 } (FamEqn (NoExtField) - ({ DumpParsedAst.hs:10:3-8 } + ({ DumpParsedAst.hs:11:3-8 } (Unqual {OccName: Length})) (HsOuterImplicit (NoExtField)) [(HsValArg - ({ DumpParsedAst.hs:10:10-17 } + ({ DumpParsedAst.hs:11:10-17 } (HsParTy (NoExtField) - ({ DumpParsedAst.hs:10:11-16 } + ({ DumpParsedAst.hs:11:11-16 } (HsOpTy (NoExtField) - ({ DumpParsedAst.hs:10:11 } + ({ DumpParsedAst.hs:11:11 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpParsedAst.hs:10:11 } + ({ DumpParsedAst.hs:11:11 } (Unqual {OccName: a})))) - ({ DumpParsedAst.hs:10:13 } + ({ DumpParsedAst.hs:11:13 } (Exact {Name: :})) - ({ DumpParsedAst.hs:10:15-16 } + ({ DumpParsedAst.hs:11:15-16 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpParsedAst.hs:10:15-16 } + ({ DumpParsedAst.hs:11:15-16 } (Unqual {OccName: as})))))))))] (Prefix) - ({ DumpParsedAst.hs:10:21-36 } + ({ DumpParsedAst.hs:11:21-36 } (HsAppTy (NoExtField) - ({ DumpParsedAst.hs:10:21-24 } + ({ DumpParsedAst.hs:11:21-24 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpParsedAst.hs:10:21-24 } + ({ DumpParsedAst.hs:11:21-24 } (Unqual {OccName: Succ})))) - ({ DumpParsedAst.hs:10:26-36 } + ({ DumpParsedAst.hs:11:26-36 } (HsParTy (NoExtField) - ({ DumpParsedAst.hs:10:27-35 } + ({ DumpParsedAst.hs:11:27-35 } (HsAppTy (NoExtField) - ({ DumpParsedAst.hs:10:27-32 } + ({ DumpParsedAst.hs:11:27-32 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpParsedAst.hs:10:27-32 } + ({ DumpParsedAst.hs:11:27-32 } (Unqual {OccName: Length})))) - ({ DumpParsedAst.hs:10:34-35 } + ({ DumpParsedAst.hs:11:34-35 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpParsedAst.hs:10:34-35 } + ({ DumpParsedAst.hs:11:34-35 } (Unqual {OccName: as})))))))))))) - ,({ DumpParsedAst.hs:11:3-24 } + ,({ DumpParsedAst.hs:12:3-24 } (FamEqn (NoExtField) - ({ DumpParsedAst.hs:11:3-8 } + ({ DumpParsedAst.hs:12:3-8 } (Unqual {OccName: Length})) (HsOuterImplicit (NoExtField)) [(HsValArg - ({ DumpParsedAst.hs:11:10-12 } + ({ DumpParsedAst.hs:12:10-12 } (HsExplicitListTy (NoExtField) (IsPromoted) [])))] (Prefix) - ({ DumpParsedAst.hs:11:21-24 } + ({ DumpParsedAst.hs:12:21-24 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpParsedAst.hs:11:21-24 } + ({ DumpParsedAst.hs:12:21-24 } (Unqual {OccName: Zero}))))))])) - ({ DumpParsedAst.hs:9:13-18 } + ({ DumpParsedAst.hs:10:13-18 } (Unqual {OccName: Length})) (HsQTvs (NoExtField) - [({ DumpParsedAst.hs:9:21-29 } + [({ DumpParsedAst.hs:10:21-29 } (KindedTyVar (NoExtField) (()) - ({ DumpParsedAst.hs:9:21-22 } + ({ DumpParsedAst.hs:10:21-22 } (Unqual {OccName: as})) - ({ DumpParsedAst.hs:9:27-29 } + ({ DumpParsedAst.hs:10:27-29 } (HsListTy (NoExtField) - ({ DumpParsedAst.hs:9:28 } + ({ DumpParsedAst.hs:10:28 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpParsedAst.hs:9:28 } + ({ DumpParsedAst.hs:10:28 } (Unqual {OccName: k}))))))))]) (Prefix) - ({ DumpParsedAst.hs:9:32-39 } + ({ DumpParsedAst.hs:10:32-39 } (KindSig (NoExtField) - ({ DumpParsedAst.hs:9:35-39 } + ({ DumpParsedAst.hs:10:35-39 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpParsedAst.hs:9:35-39 } + ({ DumpParsedAst.hs:10:35-39 } (Unqual {OccName: Peano})))))) (Nothing))))) - ,({ DumpParsedAst.hs:14:1-29 } + ,({ DumpParsedAst.hs:15:1-29 } (TyClD (NoExtField) (DataDecl (NoExtField) - ({ DumpParsedAst.hs:14:6 } + ({ DumpParsedAst.hs:15:6 } (Unqual {OccName: T})) (HsQTvs (NoExtField) - [({ DumpParsedAst.hs:14:8 } + [({ DumpParsedAst.hs:15:8 } (UserTyVar (NoExtField) (()) - ({ DumpParsedAst.hs:14:8 } + ({ DumpParsedAst.hs:15:8 } (Unqual {OccName: f})))) - ,({ DumpParsedAst.hs:14:11-16 } + ,({ DumpParsedAst.hs:15:11-16 } (KindedTyVar (NoExtField) (()) - ({ DumpParsedAst.hs:14:11 } + ({ DumpParsedAst.hs:15:11 } (Unqual {OccName: a})) - ({ DumpParsedAst.hs:14:16 } + ({ DumpParsedAst.hs:15:16 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpParsedAst.hs:14:16 } + ({ DumpParsedAst.hs:15:16 } (Unqual {OccName: k}))))))]) (Prefix) @@ -245,10 +245,10 @@ (Nothing) (Nothing) (Nothing) - [({ DumpParsedAst.hs:14:21-29 } + [({ DumpParsedAst.hs:15:21-29 } (ConDeclH98 (NoExtField) - ({ DumpParsedAst.hs:14:21-23 } + ({ DumpParsedAst.hs:15:21-23 } (Unqual {OccName: MkT})) ({ <no location info> } @@ -260,30 +260,30 @@ [(HsScaled (HsLinearArrow (NormalSyntax)) - ({ DumpParsedAst.hs:14:25-29 } + ({ DumpParsedAst.hs:15:25-29 } (HsParTy (NoExtField) - ({ DumpParsedAst.hs:14:26-28 } + ({ DumpParsedAst.hs:15:26-28 } (HsAppTy (NoExtField) - ({ DumpParsedAst.hs:14:26 } + ({ DumpParsedAst.hs:15:26 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpParsedAst.hs:14:26 } + ({ DumpParsedAst.hs:15:26 } (Unqual {OccName: f})))) - ({ DumpParsedAst.hs:14:28 } + ({ DumpParsedAst.hs:15:28 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpParsedAst.hs:14:28 } + ({ DumpParsedAst.hs:15:28 } (Unqual {OccName: a})))))))))]) (Nothing)))] ({ <no location info> } []))))) - ,({ DumpParsedAst.hs:16:1-48 } + ,({ DumpParsedAst.hs:17:1-48 } (TyClD (NoExtField) (FamDecl @@ -292,150 +292,150 @@ (NoExtField) (ClosedTypeFamily (Just - [({ DumpParsedAst.hs:17:3-30 } + [({ DumpParsedAst.hs:18:3-30 } (FamEqn (NoExtField) - ({ DumpParsedAst.hs:17:3-4 } + ({ DumpParsedAst.hs:18:3-4 } (Unqual {OccName: F1})) (HsOuterImplicit (NoExtField)) [(HsTypeArg - { DumpParsedAst.hs:17:6-11 } - ({ DumpParsedAst.hs:17:7-11 } + { DumpParsedAst.hs:18:6-11 } + ({ DumpParsedAst.hs:18:7-11 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpParsedAst.hs:17:7-11 } + ({ DumpParsedAst.hs:18:7-11 } (Unqual {OccName: Peano}))))) ,(HsValArg - ({ DumpParsedAst.hs:17:13 } + ({ DumpParsedAst.hs:18:13 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpParsedAst.hs:17:13 } + ({ DumpParsedAst.hs:18:13 } (Unqual {OccName: a}))))) ,(HsValArg - ({ DumpParsedAst.hs:17:15 } + ({ DumpParsedAst.hs:18:15 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpParsedAst.hs:17:15 } + ({ DumpParsedAst.hs:18:15 } (Unqual {OccName: f})))))] (Prefix) - ({ DumpParsedAst.hs:17:19-30 } + ({ DumpParsedAst.hs:18:19-30 } (HsAppTy (NoExtField) - ({ DumpParsedAst.hs:17:19-28 } + ({ DumpParsedAst.hs:18:19-28 } (HsAppTy (NoExtField) - ({ DumpParsedAst.hs:17:19-26 } + ({ DumpParsedAst.hs:18:19-26 } (HsAppKindTy - { DumpParsedAst.hs:17:21-26 } - ({ DumpParsedAst.hs:17:19 } + { DumpParsedAst.hs:18:21-26 } + ({ DumpParsedAst.hs:18:19 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpParsedAst.hs:17:19 } + ({ DumpParsedAst.hs:18:19 } (Unqual {OccName: T})))) - ({ DumpParsedAst.hs:17:22-26 } + ({ DumpParsedAst.hs:18:22-26 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpParsedAst.hs:17:22-26 } + ({ DumpParsedAst.hs:18:22-26 } (Unqual {OccName: Peano})))))) - ({ DumpParsedAst.hs:17:28 } + ({ DumpParsedAst.hs:18:28 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpParsedAst.hs:17:28 } + ({ DumpParsedAst.hs:18:28 } (Unqual {OccName: f})))))) - ({ DumpParsedAst.hs:17:30 } + ({ DumpParsedAst.hs:18:30 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpParsedAst.hs:17:30 } + ({ DumpParsedAst.hs:18:30 } (Unqual {OccName: a}))))))))])) - ({ DumpParsedAst.hs:16:13-14 } + ({ DumpParsedAst.hs:17:13-14 } (Unqual {OccName: F1})) (HsQTvs (NoExtField) - [({ DumpParsedAst.hs:16:17-22 } + [({ DumpParsedAst.hs:17:17-22 } (KindedTyVar (NoExtField) (()) - ({ DumpParsedAst.hs:16:17 } + ({ DumpParsedAst.hs:17:17 } (Unqual {OccName: a})) - ({ DumpParsedAst.hs:16:22 } + ({ DumpParsedAst.hs:17:22 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpParsedAst.hs:16:22 } + ({ DumpParsedAst.hs:17:22 } (Unqual {OccName: k})))))) - ,({ DumpParsedAst.hs:16:26-39 } + ,({ DumpParsedAst.hs:17:26-39 } (KindedTyVar (NoExtField) (()) - ({ DumpParsedAst.hs:16:26 } + ({ DumpParsedAst.hs:17:26 } (Unqual {OccName: f})) - ({ DumpParsedAst.hs:16:31-39 } + ({ DumpParsedAst.hs:17:31-39 } (HsFunTy (NoExtField) (HsUnrestrictedArrow (NormalSyntax)) - ({ DumpParsedAst.hs:16:31 } + ({ DumpParsedAst.hs:17:31 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpParsedAst.hs:16:31 } + ({ DumpParsedAst.hs:17:31 } (Unqual {OccName: k})))) - ({ DumpParsedAst.hs:16:36-39 } + ({ DumpParsedAst.hs:17:36-39 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpParsedAst.hs:16:36-39 } + ({ DumpParsedAst.hs:17:36-39 } (Unqual {OccName: Type}))))))))]) (Prefix) - ({ DumpParsedAst.hs:16:42-48 } + ({ DumpParsedAst.hs:17:42-48 } (KindSig (NoExtField) - ({ DumpParsedAst.hs:16:45-48 } + ({ DumpParsedAst.hs:17:45-48 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpParsedAst.hs:16:45-48 } + ({ DumpParsedAst.hs:17:45-48 } (Unqual {OccName: Type})))))) (Nothing))))) - ,({ DumpParsedAst.hs:19:1-23 } + ,({ DumpParsedAst.hs:20:1-23 } (ValD (NoExtField) (FunBind (NoExtField) - ({ DumpParsedAst.hs:19:1-4 } + ({ DumpParsedAst.hs:20:1-4 } (Unqual {OccName: main})) (MG (NoExtField) - ({ DumpParsedAst.hs:19:1-23 } - [({ DumpParsedAst.hs:19:1-23 } + ({ DumpParsedAst.hs:20:1-23 } + [({ DumpParsedAst.hs:20:1-23 } (Match (NoExtField) (FunRhs - ({ DumpParsedAst.hs:19:1-4 } + ({ DumpParsedAst.hs:20:1-4 } (Unqual {OccName: main})) (Prefix) @@ -443,20 +443,20 @@ [] (GRHSs (NoExtField) - [({ DumpParsedAst.hs:19:6-23 } + [({ DumpParsedAst.hs:20:6-23 } (GRHS (NoExtField) [] - ({ DumpParsedAst.hs:19:8-23 } + ({ DumpParsedAst.hs:20:8-23 } (HsApp (NoExtField) - ({ DumpParsedAst.hs:19:8-15 } + ({ DumpParsedAst.hs:20:8-15 } (HsVar (NoExtField) - ({ DumpParsedAst.hs:19:8-15 } + ({ DumpParsedAst.hs:20:8-15 } (Unqual {OccName: putStrLn})))) - ({ DumpParsedAst.hs:19:17-23 } + ({ DumpParsedAst.hs:20:17-23 } (HsLit (NoExtField) (HsString diff --git a/testsuite/tests/parser/should_compile/DumpRenamedAst.hs b/testsuite/tests/parser/should_compile/DumpRenamedAst.hs index d5be8627be5f..a0cb8a36b65a 100644 --- a/testsuite/tests/parser/should_compile/DumpRenamedAst.hs +++ b/testsuite/tests/parser/should_compile/DumpRenamedAst.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE DataKinds, GADTs, PolyKinds, RankNTypes, TypeOperators, TypeFamilies, StarIsType, TypeApplications #-} diff --git a/testsuite/tests/parser/should_compile/DumpRenamedAst.stderr b/testsuite/tests/parser/should_compile/DumpRenamedAst.stderr index 57d4f3fcf7f2..ec4c1dd9bdb9 100644 --- a/testsuite/tests/parser/should_compile/DumpRenamedAst.stderr +++ b/testsuite/tests/parser/should_compile/DumpRenamedAst.stderr @@ -10,39 +10,39 @@ [((,) (NonRecursive) {Bag(Located (HsBind Name)): - [({ DumpRenamedAst.hs:26:1-23 } + [({ DumpRenamedAst.hs:27:1-23 } (FunBind {NameSet: []} - ({ DumpRenamedAst.hs:26:1-4 } + ({ DumpRenamedAst.hs:27:1-4 } {Name: DumpRenamedAst.main}) (MG (NoExtField) - ({ DumpRenamedAst.hs:26:1-23 } - [({ DumpRenamedAst.hs:26:1-23 } + ({ DumpRenamedAst.hs:27:1-23 } + [({ DumpRenamedAst.hs:27:1-23 } (Match (NoExtField) (FunRhs - ({ DumpRenamedAst.hs:26:1-4 } + ({ DumpRenamedAst.hs:27:1-4 } {Name: DumpRenamedAst.main}) (Prefix) (NoSrcStrict)) [] (GRHSs (NoExtField) - [({ DumpRenamedAst.hs:26:6-23 } + [({ DumpRenamedAst.hs:27:6-23 } (GRHS (NoExtField) [] - ({ DumpRenamedAst.hs:26:8-23 } + ({ DumpRenamedAst.hs:27:8-23 } (HsApp (NoExtField) - ({ DumpRenamedAst.hs:26:8-15 } + ({ DumpRenamedAst.hs:27:8-15 } (HsVar (NoExtField) - ({ DumpRenamedAst.hs:26:8-15 } + ({ DumpRenamedAst.hs:27:8-15 } {Name: System.IO.putStrLn}))) - ({ DumpRenamedAst.hs:26:17-23 } + ({ DumpRenamedAst.hs:27:17-23 } (HsLit (NoExtField) (HsString @@ -58,13 +58,13 @@ [] [(TyClGroup (NoExtField) - [({ DumpRenamedAst.hs:9:1-30 } + [({ DumpRenamedAst.hs:10:1-30 } (DataDecl (DataDeclRn (True) {NameSet: [{Name: DumpRenamedAst.Peano}]}) - ({ DumpRenamedAst.hs:9:6-10 } + ({ DumpRenamedAst.hs:10:6-10 } {Name: DumpRenamedAst.Peano}) (HsQTvs [] @@ -76,10 +76,10 @@ (Nothing) (Nothing) (Nothing) - [({ DumpRenamedAst.hs:9:14-17 } + [({ DumpRenamedAst.hs:10:14-17 } (ConDeclH98 (NoExtField) - ({ DumpRenamedAst.hs:9:14-17 } + ({ DumpRenamedAst.hs:10:14-17 } {Name: DumpRenamedAst.Zero}) ({ <no location info> } (False)) @@ -89,10 +89,10 @@ [] []) (Nothing))) - ,({ DumpRenamedAst.hs:9:21-30 } + ,({ DumpRenamedAst.hs:10:21-30 } (ConDeclH98 (NoExtField) - ({ DumpRenamedAst.hs:9:21-24 } + ({ DumpRenamedAst.hs:10:21-24 } {Name: DumpRenamedAst.Succ}) ({ <no location info> } (False)) @@ -103,11 +103,11 @@ [(HsScaled (HsLinearArrow (NormalSyntax)) - ({ DumpRenamedAst.hs:9:26-30 } + ({ DumpRenamedAst.hs:10:26-30 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:9:26-30 } + ({ DumpRenamedAst.hs:10:26-30 } {Name: DumpRenamedAst.Peano}))))]) (Nothing)))] ({ <no location info> } @@ -117,118 +117,118 @@ []) ,(TyClGroup (NoExtField) - [({ DumpRenamedAst.hs:11:1-39 } + [({ DumpRenamedAst.hs:12:1-39 } (FamDecl (NoExtField) (FamilyDecl (NoExtField) (ClosedTypeFamily (Just - [({ DumpRenamedAst.hs:12:3-36 } + [({ DumpRenamedAst.hs:13:3-36 } (FamEqn (NoExtField) - ({ DumpRenamedAst.hs:12:3-8 } + ({ DumpRenamedAst.hs:13:3-8 } {Name: DumpRenamedAst.Length}) (HsOuterImplicit [{Name: a} ,{Name: as}]) [(HsValArg - ({ DumpRenamedAst.hs:12:10-17 } + ({ DumpRenamedAst.hs:13:10-17 } (HsParTy (NoExtField) - ({ DumpRenamedAst.hs:12:11-16 } + ({ DumpRenamedAst.hs:13:11-16 } (HsOpTy (NoExtField) - ({ DumpRenamedAst.hs:12:11 } + ({ DumpRenamedAst.hs:13:11 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:12:11 } + ({ DumpRenamedAst.hs:13:11 } {Name: a}))) - ({ DumpRenamedAst.hs:12:13 } + ({ DumpRenamedAst.hs:13:13 } {Name: :}) - ({ DumpRenamedAst.hs:12:15-16 } + ({ DumpRenamedAst.hs:13:15-16 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:12:15-16 } + ({ DumpRenamedAst.hs:13:15-16 } {Name: as}))))))))] (Prefix) - ({ DumpRenamedAst.hs:12:21-36 } + ({ DumpRenamedAst.hs:13:21-36 } (HsAppTy (NoExtField) - ({ DumpRenamedAst.hs:12:21-24 } + ({ DumpRenamedAst.hs:13:21-24 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:12:21-24 } + ({ DumpRenamedAst.hs:13:21-24 } {Name: DumpRenamedAst.Succ}))) - ({ DumpRenamedAst.hs:12:26-36 } + ({ DumpRenamedAst.hs:13:26-36 } (HsParTy (NoExtField) - ({ DumpRenamedAst.hs:12:27-35 } + ({ DumpRenamedAst.hs:13:27-35 } (HsAppTy (NoExtField) - ({ DumpRenamedAst.hs:12:27-32 } + ({ DumpRenamedAst.hs:13:27-32 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:12:27-32 } + ({ DumpRenamedAst.hs:13:27-32 } {Name: DumpRenamedAst.Length}))) - ({ DumpRenamedAst.hs:12:34-35 } + ({ DumpRenamedAst.hs:13:34-35 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:12:34-35 } + ({ DumpRenamedAst.hs:13:34-35 } {Name: as}))))))))))) - ,({ DumpRenamedAst.hs:13:3-24 } + ,({ DumpRenamedAst.hs:14:3-24 } (FamEqn (NoExtField) - ({ DumpRenamedAst.hs:13:3-8 } + ({ DumpRenamedAst.hs:14:3-8 } {Name: DumpRenamedAst.Length}) (HsOuterImplicit []) [(HsValArg - ({ DumpRenamedAst.hs:13:10-12 } + ({ DumpRenamedAst.hs:14:10-12 } (HsExplicitListTy (NoExtField) (IsPromoted) [])))] (Prefix) - ({ DumpRenamedAst.hs:13:21-24 } + ({ DumpRenamedAst.hs:14:21-24 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:13:21-24 } + ({ DumpRenamedAst.hs:14:21-24 } {Name: DumpRenamedAst.Zero})))))])) - ({ DumpRenamedAst.hs:11:13-18 } + ({ DumpRenamedAst.hs:12:13-18 } {Name: DumpRenamedAst.Length}) (HsQTvs [{Name: k}] - [({ DumpRenamedAst.hs:11:21-29 } + [({ DumpRenamedAst.hs:12:21-29 } (KindedTyVar (NoExtField) (()) - ({ DumpRenamedAst.hs:11:21-22 } + ({ DumpRenamedAst.hs:12:21-22 } {Name: as}) - ({ DumpRenamedAst.hs:11:27-29 } + ({ DumpRenamedAst.hs:12:27-29 } (HsListTy (NoExtField) - ({ DumpRenamedAst.hs:11:28 } + ({ DumpRenamedAst.hs:12:28 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:11:28 } + ({ DumpRenamedAst.hs:12:28 } {Name: k})))))))]) (Prefix) - ({ DumpRenamedAst.hs:11:32-39 } + ({ DumpRenamedAst.hs:12:32-39 } (KindSig (NoExtField) - ({ DumpRenamedAst.hs:11:35-39 } + ({ DumpRenamedAst.hs:12:35-39 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:11:35-39 } + ({ DumpRenamedAst.hs:12:35-39 } {Name: DumpRenamedAst.Peano}))))) (Nothing))))] [] @@ -236,92 +236,92 @@ []) ,(TyClGroup (NoExtField) - [({ DumpRenamedAst.hs:15:1-33 } + [({ DumpRenamedAst.hs:16:1-33 } (FamDecl (NoExtField) (FamilyDecl (NoExtField) (DataFamily) - ({ DumpRenamedAst.hs:15:13-15 } + ({ DumpRenamedAst.hs:16:13-15 } {Name: DumpRenamedAst.Nat}) (HsQTvs [{Name: k}] []) (Prefix) - ({ DumpRenamedAst.hs:15:17-33 } + ({ DumpRenamedAst.hs:16:17-33 } (KindSig (NoExtField) - ({ DumpRenamedAst.hs:15:20-33 } + ({ DumpRenamedAst.hs:16:20-33 } (HsFunTy (NoExtField) (HsUnrestrictedArrow (NormalSyntax)) - ({ DumpRenamedAst.hs:15:20 } + ({ DumpRenamedAst.hs:16:20 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:15:20 } + ({ DumpRenamedAst.hs:16:20 } {Name: k}))) - ({ DumpRenamedAst.hs:15:25-33 } + ({ DumpRenamedAst.hs:16:25-33 } (HsFunTy (NoExtField) (HsUnrestrictedArrow (NormalSyntax)) - ({ DumpRenamedAst.hs:15:25 } + ({ DumpRenamedAst.hs:16:25 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:15:25 } + ({ DumpRenamedAst.hs:16:25 } {Name: k}))) - ({ DumpRenamedAst.hs:15:30-33 } + ({ DumpRenamedAst.hs:16:30-33 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:15:30-33 } + ({ DumpRenamedAst.hs:16:30-33 } {Name: GHC.Types.Type}))))))))) (Nothing))))] [] [] - [({ DumpRenamedAst.hs:(18,1)-(19,45) } + [({ DumpRenamedAst.hs:(19,1)-(20,45) } (DataFamInstD (NoExtField) (DataFamInstDecl (FamEqn (NoExtField) - ({ DumpRenamedAst.hs:18:18-20 } + ({ DumpRenamedAst.hs:19:18-20 } {Name: DumpRenamedAst.Nat}) (HsOuterImplicit [{Name: a} ,{Name: k}]) [(HsValArg - ({ DumpRenamedAst.hs:18:22-37 } + ({ DumpRenamedAst.hs:19:22-37 } (HsParTy (NoExtField) - ({ DumpRenamedAst.hs:18:23-36 } + ({ DumpRenamedAst.hs:19:23-36 } (HsKindSig (NoExtField) - ({ DumpRenamedAst.hs:18:23 } + ({ DumpRenamedAst.hs:19:23 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:18:23 } + ({ DumpRenamedAst.hs:19:23 } {Name: a}))) - ({ DumpRenamedAst.hs:18:28-36 } + ({ DumpRenamedAst.hs:19:28-36 } (HsFunTy (NoExtField) (HsUnrestrictedArrow (NormalSyntax)) - ({ DumpRenamedAst.hs:18:28 } + ({ DumpRenamedAst.hs:19:28 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:18:28 } + ({ DumpRenamedAst.hs:19:28 } {Name: k}))) - ({ DumpRenamedAst.hs:18:33-36 } + ({ DumpRenamedAst.hs:19:33-36 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:18:33-36 } + ({ DumpRenamedAst.hs:19:33-36 } {Name: GHC.Types.Type}))))))))))] (Prefix) (HsDataDefn @@ -330,43 +330,43 @@ (Nothing) (Nothing) (Just - ({ DumpRenamedAst.hs:18:42-60 } + ({ DumpRenamedAst.hs:19:42-60 } (HsFunTy (NoExtField) (HsUnrestrictedArrow (NormalSyntax)) - ({ DumpRenamedAst.hs:18:42-52 } + ({ DumpRenamedAst.hs:19:42-52 } (HsParTy (NoExtField) - ({ DumpRenamedAst.hs:18:43-51 } + ({ DumpRenamedAst.hs:19:43-51 } (HsFunTy (NoExtField) (HsUnrestrictedArrow (NormalSyntax)) - ({ DumpRenamedAst.hs:18:43 } + ({ DumpRenamedAst.hs:19:43 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:18:43 } + ({ DumpRenamedAst.hs:19:43 } {Name: k}))) - ({ DumpRenamedAst.hs:18:48-51 } + ({ DumpRenamedAst.hs:19:48-51 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:18:48-51 } + ({ DumpRenamedAst.hs:19:48-51 } {Name: GHC.Types.Type}))))))) - ({ DumpRenamedAst.hs:18:57-60 } + ({ DumpRenamedAst.hs:19:57-60 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:18:57-60 } + ({ DumpRenamedAst.hs:19:57-60 } {Name: GHC.Types.Type})))))) - [({ DumpRenamedAst.hs:19:3-45 } + [({ DumpRenamedAst.hs:20:3-45 } (ConDeclGADT (NoExtField) - [({ DumpRenamedAst.hs:19:3-5 } + [({ DumpRenamedAst.hs:20:3-5 } {Name: DumpRenamedAst.Nat})] - ({ DumpRenamedAst.hs:19:10-45 } + ({ DumpRenamedAst.hs:20:10-45 } (HsOuterImplicit [{Name: f} ,{Name: g}])) @@ -375,112 +375,112 @@ [(HsScaled (HsUnrestrictedArrow (NormalSyntax)) - ({ DumpRenamedAst.hs:19:10-34 } + ({ DumpRenamedAst.hs:20:10-34 } (HsParTy (NoExtField) - ({ DumpRenamedAst.hs:19:11-33 } + ({ DumpRenamedAst.hs:20:11-33 } (HsForAllTy (NoExtField) (HsForAllInvis (NoExtField) - [({ DumpRenamedAst.hs:19:18-19 } + [({ DumpRenamedAst.hs:20:18-19 } (UserTyVar (NoExtField) (SpecifiedSpec) - ({ DumpRenamedAst.hs:19:18-19 } + ({ DumpRenamedAst.hs:20:18-19 } {Name: xx})))]) - ({ DumpRenamedAst.hs:19:22-33 } + ({ DumpRenamedAst.hs:20:22-33 } (HsFunTy (NoExtField) (HsUnrestrictedArrow (NormalSyntax)) - ({ DumpRenamedAst.hs:19:22-25 } + ({ DumpRenamedAst.hs:20:22-25 } (HsAppTy (NoExtField) - ({ DumpRenamedAst.hs:19:22 } + ({ DumpRenamedAst.hs:20:22 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:19:22 } + ({ DumpRenamedAst.hs:20:22 } {Name: f}))) - ({ DumpRenamedAst.hs:19:24-25 } + ({ DumpRenamedAst.hs:20:24-25 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:19:24-25 } + ({ DumpRenamedAst.hs:20:24-25 } {Name: xx}))))) - ({ DumpRenamedAst.hs:19:30-33 } + ({ DumpRenamedAst.hs:20:30-33 } (HsAppTy (NoExtField) - ({ DumpRenamedAst.hs:19:30 } + ({ DumpRenamedAst.hs:20:30 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:19:30 } + ({ DumpRenamedAst.hs:20:30 } {Name: g}))) - ({ DumpRenamedAst.hs:19:32-33 } + ({ DumpRenamedAst.hs:20:32-33 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:19:32-33 } + ({ DumpRenamedAst.hs:20:32-33 } {Name: xx}))))))))))))]) - ({ DumpRenamedAst.hs:19:39-45 } + ({ DumpRenamedAst.hs:20:39-45 } (HsAppTy (NoExtField) - ({ DumpRenamedAst.hs:19:39-43 } + ({ DumpRenamedAst.hs:20:39-43 } (HsAppTy (NoExtField) - ({ DumpRenamedAst.hs:19:39-41 } + ({ DumpRenamedAst.hs:20:39-41 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:19:39-41 } + ({ DumpRenamedAst.hs:20:39-41 } {Name: DumpRenamedAst.Nat}))) - ({ DumpRenamedAst.hs:19:43 } + ({ DumpRenamedAst.hs:20:43 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:19:43 } + ({ DumpRenamedAst.hs:20:43 } {Name: f}))))) - ({ DumpRenamedAst.hs:19:45 } + ({ DumpRenamedAst.hs:20:45 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:19:45 } + ({ DumpRenamedAst.hs:20:45 } {Name: g}))))) (Nothing)))] ({ <no location info> } []))))))]) ,(TyClGroup (NoExtField) - [({ DumpRenamedAst.hs:21:1-29 } + [({ DumpRenamedAst.hs:22:1-29 } (DataDecl (DataDeclRn (False) {NameSet: [{Name: a} ,{Name: f}]}) - ({ DumpRenamedAst.hs:21:6 } + ({ DumpRenamedAst.hs:22:6 } {Name: DumpRenamedAst.T}) (HsQTvs [{Name: k}] - [({ DumpRenamedAst.hs:21:8 } + [({ DumpRenamedAst.hs:22:8 } (UserTyVar (NoExtField) (()) - ({ DumpRenamedAst.hs:21:8 } + ({ DumpRenamedAst.hs:22:8 } {Name: f}))) - ,({ DumpRenamedAst.hs:21:11-16 } + ,({ DumpRenamedAst.hs:22:11-16 } (KindedTyVar (NoExtField) (()) - ({ DumpRenamedAst.hs:21:11 } + ({ DumpRenamedAst.hs:22:11 } {Name: a}) - ({ DumpRenamedAst.hs:21:16 } + ({ DumpRenamedAst.hs:22:16 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:21:16 } + ({ DumpRenamedAst.hs:22:16 } {Name: k})))))]) (Prefix) (HsDataDefn @@ -489,10 +489,10 @@ (Nothing) (Nothing) (Nothing) - [({ DumpRenamedAst.hs:21:21-29 } + [({ DumpRenamedAst.hs:22:21-29 } (ConDeclH98 (NoExtField) - ({ DumpRenamedAst.hs:21:21-23 } + ({ DumpRenamedAst.hs:22:21-23 } {Name: DumpRenamedAst.MkT}) ({ <no location info> } (False)) @@ -503,23 +503,23 @@ [(HsScaled (HsLinearArrow (NormalSyntax)) - ({ DumpRenamedAst.hs:21:25-29 } + ({ DumpRenamedAst.hs:22:25-29 } (HsParTy (NoExtField) - ({ DumpRenamedAst.hs:21:26-28 } + ({ DumpRenamedAst.hs:22:26-28 } (HsAppTy (NoExtField) - ({ DumpRenamedAst.hs:21:26 } + ({ DumpRenamedAst.hs:22:26 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:21:26 } + ({ DumpRenamedAst.hs:22:26 } {Name: f}))) - ({ DumpRenamedAst.hs:21:28 } + ({ DumpRenamedAst.hs:22:28 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:21:28 } + ({ DumpRenamedAst.hs:22:28 } {Name: a}))))))))]) (Nothing)))] ({ <no location info> } @@ -529,125 +529,125 @@ []) ,(TyClGroup (NoExtField) - [({ DumpRenamedAst.hs:23:1-48 } + [({ DumpRenamedAst.hs:24:1-48 } (FamDecl (NoExtField) (FamilyDecl (NoExtField) (ClosedTypeFamily (Just - [({ DumpRenamedAst.hs:24:3-30 } + [({ DumpRenamedAst.hs:25:3-30 } (FamEqn (NoExtField) - ({ DumpRenamedAst.hs:24:3-4 } + ({ DumpRenamedAst.hs:25:3-4 } {Name: DumpRenamedAst.F1}) (HsOuterImplicit [{Name: a} ,{Name: f}]) [(HsTypeArg - { DumpRenamedAst.hs:24:6-11 } - ({ DumpRenamedAst.hs:24:7-11 } + { DumpRenamedAst.hs:25:6-11 } + ({ DumpRenamedAst.hs:25:7-11 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:24:7-11 } + ({ DumpRenamedAst.hs:25:7-11 } {Name: DumpRenamedAst.Peano})))) ,(HsValArg - ({ DumpRenamedAst.hs:24:13 } + ({ DumpRenamedAst.hs:25:13 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:24:13 } + ({ DumpRenamedAst.hs:25:13 } {Name: a})))) ,(HsValArg - ({ DumpRenamedAst.hs:24:15 } + ({ DumpRenamedAst.hs:25:15 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:24:15 } + ({ DumpRenamedAst.hs:25:15 } {Name: f}))))] (Prefix) - ({ DumpRenamedAst.hs:24:19-30 } + ({ DumpRenamedAst.hs:25:19-30 } (HsAppTy (NoExtField) - ({ DumpRenamedAst.hs:24:19-28 } + ({ DumpRenamedAst.hs:25:19-28 } (HsAppTy (NoExtField) - ({ DumpRenamedAst.hs:24:19-26 } + ({ DumpRenamedAst.hs:25:19-26 } (HsAppKindTy - { DumpRenamedAst.hs:24:21-26 } - ({ DumpRenamedAst.hs:24:19 } + { DumpRenamedAst.hs:25:21-26 } + ({ DumpRenamedAst.hs:25:19 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:24:19 } + ({ DumpRenamedAst.hs:25:19 } {Name: DumpRenamedAst.T}))) - ({ DumpRenamedAst.hs:24:22-26 } + ({ DumpRenamedAst.hs:25:22-26 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:24:22-26 } + ({ DumpRenamedAst.hs:25:22-26 } {Name: DumpRenamedAst.Peano}))))) - ({ DumpRenamedAst.hs:24:28 } + ({ DumpRenamedAst.hs:25:28 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:24:28 } + ({ DumpRenamedAst.hs:25:28 } {Name: f}))))) - ({ DumpRenamedAst.hs:24:30 } + ({ DumpRenamedAst.hs:25:30 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:24:30 } + ({ DumpRenamedAst.hs:25:30 } {Name: a})))))))])) - ({ DumpRenamedAst.hs:23:13-14 } + ({ DumpRenamedAst.hs:24:13-14 } {Name: DumpRenamedAst.F1}) (HsQTvs [{Name: k}] - [({ DumpRenamedAst.hs:23:17-22 } + [({ DumpRenamedAst.hs:24:17-22 } (KindedTyVar (NoExtField) (()) - ({ DumpRenamedAst.hs:23:17 } + ({ DumpRenamedAst.hs:24:17 } {Name: a}) - ({ DumpRenamedAst.hs:23:22 } + ({ DumpRenamedAst.hs:24:22 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:23:22 } + ({ DumpRenamedAst.hs:24:22 } {Name: k}))))) - ,({ DumpRenamedAst.hs:23:26-39 } + ,({ DumpRenamedAst.hs:24:26-39 } (KindedTyVar (NoExtField) (()) - ({ DumpRenamedAst.hs:23:26 } + ({ DumpRenamedAst.hs:24:26 } {Name: f}) - ({ DumpRenamedAst.hs:23:31-39 } + ({ DumpRenamedAst.hs:24:31-39 } (HsFunTy (NoExtField) (HsUnrestrictedArrow (NormalSyntax)) - ({ DumpRenamedAst.hs:23:31 } + ({ DumpRenamedAst.hs:24:31 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:23:31 } + ({ DumpRenamedAst.hs:24:31 } {Name: k}))) - ({ DumpRenamedAst.hs:23:36-39 } + ({ DumpRenamedAst.hs:24:36-39 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:23:36-39 } + ({ DumpRenamedAst.hs:24:36-39 } {Name: GHC.Types.Type})))))))]) (Prefix) - ({ DumpRenamedAst.hs:23:42-48 } + ({ DumpRenamedAst.hs:24:42-48 } (KindSig (NoExtField) - ({ DumpRenamedAst.hs:23:45-48 } + ({ DumpRenamedAst.hs:24:45-48 } (HsTyVar (NoExtField) (NotPromoted) - ({ DumpRenamedAst.hs:23:45-48 } + ({ DumpRenamedAst.hs:24:45-48 } {Name: GHC.Types.Type}))))) (Nothing))))] [] @@ -661,11 +661,11 @@ [] [] []) - [({ DumpRenamedAst.hs:4:8-21 } + [({ DumpRenamedAst.hs:5:8-21 } (ImportDecl (NoExtField) (NoSourceText) - ({ DumpRenamedAst.hs:4:8-21 } + ({ DumpRenamedAst.hs:5:8-21 } {ModuleName: Prelude}) (Nothing) (NotBoot) @@ -674,11 +674,11 @@ (True) (Nothing) (Nothing))) - ,({ DumpRenamedAst.hs:5:1-16 } + ,({ DumpRenamedAst.hs:6:1-16 } (ImportDecl (NoExtField) (NoSourceText) - ({ DumpRenamedAst.hs:5:8-16 } + ({ DumpRenamedAst.hs:6:8-16 } {ModuleName: Data.Kind}) (Nothing) (NotBoot) @@ -687,11 +687,11 @@ (False) (Nothing) (Nothing))) - ,({ DumpRenamedAst.hs:7:1-23 } + ,({ DumpRenamedAst.hs:8:1-23 } (ImportDecl (NoExtField) (NoSourceText) - ({ DumpRenamedAst.hs:7:8-16 } + ({ DumpRenamedAst.hs:8:8-16 } {ModuleName: Data.Kind}) (Nothing) (NotBoot) @@ -702,13 +702,13 @@ (Just ((,) (False) - ({ DumpRenamedAst.hs:7:18-23 } - [({ DumpRenamedAst.hs:7:19-22 } + ({ DumpRenamedAst.hs:8:18-23 } + [({ DumpRenamedAst.hs:8:19-22 } (IEThingAbs (NoExtField) - ({ DumpRenamedAst.hs:7:19-22 } + ({ DumpRenamedAst.hs:8:19-22 } (IEName - ({ DumpRenamedAst.hs:7:19-22 } + ({ DumpRenamedAst.hs:8:19-22 } {Name: GHC.Types.Type})))))])))))] (Nothing) (Nothing))) diff --git a/testsuite/tests/parser/should_compile/DumpTypecheckedAst.hs b/testsuite/tests/parser/should_compile/DumpTypecheckedAst.hs index 82cf107e5d4e..202be3f1101b 100644 --- a/testsuite/tests/parser/should_compile/DumpTypecheckedAst.hs +++ b/testsuite/tests/parser/should_compile/DumpTypecheckedAst.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE DataKinds, PolyKinds, TypeOperators, TypeFamilies , TypeApplications #-} diff --git a/testsuite/tests/parser/should_compile/DumpTypecheckedAst.stderr b/testsuite/tests/parser/should_compile/DumpTypecheckedAst.stderr index a9081bf7eb76..45488ba16531 100644 --- a/testsuite/tests/parser/should_compile/DumpTypecheckedAst.stderr +++ b/testsuite/tests/parser/should_compile/DumpTypecheckedAst.stderr @@ -691,7 +691,7 @@ (HsStringPrim (NoSourceText) "DumpTypecheckedAst"))))))))))) - ,({ DumpTypecheckedAst.hs:18:1-23 } + ,({ DumpTypecheckedAst.hs:19:1-23 } (AbsBinds (NoExtField) [] @@ -705,10 +705,10 @@ []))] [({abstract:TcEvBinds})] {Bag(Located (HsBind Var)): - [({ DumpTypecheckedAst.hs:18:1-23 } + [({ DumpTypecheckedAst.hs:19:1-23 } (FunBind (WpHole) - ({ DumpTypecheckedAst.hs:18:1-4 } + ({ DumpTypecheckedAst.hs:19:1-4 } {Var: main}) (MG (MatchGroupTc @@ -718,31 +718,31 @@ [(TyConApp ({abstract:TyCon}) [])])) - ({ DumpTypecheckedAst.hs:18:1-23 } - [({ DumpTypecheckedAst.hs:18:1-23 } + ({ DumpTypecheckedAst.hs:19:1-23 } + [({ DumpTypecheckedAst.hs:19:1-23 } (Match (NoExtField) (FunRhs - ({ DumpTypecheckedAst.hs:18:1-4 } + ({ DumpTypecheckedAst.hs:19:1-4 } {Name: main}) (Prefix) (NoSrcStrict)) [] (GRHSs (NoExtField) - [({ DumpTypecheckedAst.hs:18:6-23 } + [({ DumpTypecheckedAst.hs:19:6-23 } (GRHS (NoExtField) [] - ({ DumpTypecheckedAst.hs:18:8-23 } + ({ DumpTypecheckedAst.hs:19:8-23 } (HsApp (NoExtField) - ({ DumpTypecheckedAst.hs:18:8-15 } + ({ DumpTypecheckedAst.hs:19:8-15 } (HsVar (NoExtField) ({ <no location info> } {Var: putStrLn}))) - ({ DumpTypecheckedAst.hs:18:17-23 } + ({ DumpTypecheckedAst.hs:19:17-23 } (HsLit (NoExtField) (HsString diff --git a/testsuite/tests/parser/should_fail/ParserNoBinaryLiterals1.hs b/testsuite/tests/parser/should_fail/ParserNoBinaryLiterals1.hs index 6b7de0f71278..a46bb6f706fd 100644 --- a/testsuite/tests/parser/should_fail/ParserNoBinaryLiterals1.hs +++ b/testsuite/tests/parser/should_fail/ParserNoBinaryLiterals1.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module ParserNoBinaryLiterals1 where f :: Int -> () diff --git a/testsuite/tests/parser/should_fail/ParserNoBinaryLiterals1.stderr b/testsuite/tests/parser/should_fail/ParserNoBinaryLiterals1.stderr index 3b57330e59fd..d222e5d11cbd 100644 --- a/testsuite/tests/parser/should_fail/ParserNoBinaryLiterals1.stderr +++ b/testsuite/tests/parser/should_fail/ParserNoBinaryLiterals1.stderr @@ -1,5 +1,5 @@ -ParserNoBinaryLiterals1.hs:4:1: +ParserNoBinaryLiterals1.hs:5:1: error: Equations for ‘f’ have different numbers of arguments - ParserNoBinaryLiterals1.hs:4:1-10 ParserNoBinaryLiterals1.hs:5:1-10 + ParserNoBinaryLiterals1.hs:6:1-10 diff --git a/testsuite/tests/parser/should_fail/ParserNoBinaryLiterals2.hs b/testsuite/tests/parser/should_fail/ParserNoBinaryLiterals2.hs index e760bd888eda..6c48c20746b0 100644 --- a/testsuite/tests/parser/should_fail/ParserNoBinaryLiterals2.hs +++ b/testsuite/tests/parser/should_fail/ParserNoBinaryLiterals2.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE MagicHash #-} module ParserNoBinaryLiterals2 where diff --git a/testsuite/tests/parser/should_fail/ParserNoBinaryLiterals2.stderr b/testsuite/tests/parser/should_fail/ParserNoBinaryLiterals2.stderr index f592bc878b0f..d45f4b55029f 100644 --- a/testsuite/tests/parser/should_fail/ParserNoBinaryLiterals2.stderr +++ b/testsuite/tests/parser/should_fail/ParserNoBinaryLiterals2.stderr @@ -1,5 +1,5 @@ -ParserNoBinaryLiterals2.hs:8:4: error: +ParserNoBinaryLiterals2.hs:9:4: error: • The constructor ‘W#’ should have 1 argument, but has been given 2 • In the pattern: W# 0 b0## In an equation for ‘f’: f (W# 0 b0##) = () diff --git a/testsuite/tests/parser/should_fail/ParserNoBinaryLiterals3.hs b/testsuite/tests/parser/should_fail/ParserNoBinaryLiterals3.hs index b6bc81b68a1d..8797358879ad 100644 --- a/testsuite/tests/parser/should_fail/ParserNoBinaryLiterals3.hs +++ b/testsuite/tests/parser/should_fail/ParserNoBinaryLiterals3.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE MagicHash #-} module ParserNoBinaryLiterals3 where diff --git a/testsuite/tests/parser/should_fail/ParserNoBinaryLiterals3.stderr b/testsuite/tests/parser/should_fail/ParserNoBinaryLiterals3.stderr index fbe4bf574c11..2d24a6dedf76 100644 --- a/testsuite/tests/parser/should_fail/ParserNoBinaryLiterals3.stderr +++ b/testsuite/tests/parser/should_fail/ParserNoBinaryLiterals3.stderr @@ -1,5 +1,5 @@ -ParserNoBinaryLiterals3.hs:8:4: error: +ParserNoBinaryLiterals3.hs:9:4: error: • The constructor ‘I#’ should have 1 argument, but has been given 2 • In the pattern: I# 0 b0# In an equation for ‘f’: f (I# 0 b0#) = () diff --git a/testsuite/tests/parser/should_fail/ParserNoForallUnicode.hs b/testsuite/tests/parser/should_fail/ParserNoForallUnicode.hs index e5591de2bf34..883d3c841ed8 100644 --- a/testsuite/tests/parser/should_fail/ParserNoForallUnicode.hs +++ b/testsuite/tests/parser/should_fail/ParserNoForallUnicode.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE UnicodeSyntax #-} module ParserNoForallUnicode where diff --git a/testsuite/tests/parser/should_fail/ParserNoForallUnicode.stderr b/testsuite/tests/parser/should_fail/ParserNoForallUnicode.stderr index 6ad0cbba11dd..81286aa49d8e 100644 --- a/testsuite/tests/parser/should_fail/ParserNoForallUnicode.stderr +++ b/testsuite/tests/parser/should_fail/ParserNoForallUnicode.stderr @@ -1,5 +1,5 @@ -ParserNoForallUnicode.hs:5:8: error: +ParserNoForallUnicode.hs:6:8: error: Illegal symbol ‘∀’ in type Perhaps you intended to use RankNTypes or a similar language extension to enable explicit-forall syntax: ∀ <tvs>. <type> diff --git a/testsuite/tests/parser/should_fail/RecordDotSyntaxFail12.hs b/testsuite/tests/parser/should_fail/RecordDotSyntaxFail12.hs index ba7f7effed68..6d306b747c98 100644 --- a/testsuite/tests/parser/should_fail/RecordDotSyntaxFail12.hs +++ b/testsuite/tests/parser/should_fail/RecordDotSyntaxFail12.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE AllowAmbiguousTypes, FunctionalDependencies, ScopedTypeVariables, PolyKinds, TypeApplications, DataKinds #-} {-# LANGUAGE RecordWildCards #-} {-# LANGUAGE OverloadedRecordDot, OverloadedRecordUpdate #-} diff --git a/testsuite/tests/parser/should_fail/RecordDotSyntaxFail12.stderr b/testsuite/tests/parser/should_fail/RecordDotSyntaxFail12.stderr index 6ef0a51754c1..f1101379cee4 100644 --- a/testsuite/tests/parser/should_fail/RecordDotSyntaxFail12.stderr +++ b/testsuite/tests/parser/should_fail/RecordDotSyntaxFail12.stderr @@ -1,36 +1,36 @@ -RecordDotSyntaxFail12.hs:123:25: +RecordDotSyntaxFail12.hs:124:25: error: Illegal use of punning for field ‘quux’ Use NamedFieldPuns to permit this -RecordDotSyntaxFail12.hs:123:46: +RecordDotSyntaxFail12.hs:124:46: error: Illegal use of punning for field ‘baz’ Use NamedFieldPuns to permit this -RecordDotSyntaxFail12.hs:123:65: +RecordDotSyntaxFail12.hs:124:65: error: Illegal use of punning for field ‘bar’ Use NamedFieldPuns to permit this -RecordDotSyntaxFail12.hs:124:11: +RecordDotSyntaxFail12.hs:125:11: error: For this to work enable NamedFieldPuns. -RecordDotSyntaxFail12.hs:125:11: +RecordDotSyntaxFail12.hs:126:11: error: For this to work enable NamedFieldPuns. -RecordDotSyntaxFail12.hs:126:11: +RecordDotSyntaxFail12.hs:127:11: error: For this to work enable NamedFieldPuns. -RecordDotSyntaxFail12.hs:127:11: +RecordDotSyntaxFail12.hs:128:11: error: For this to work enable NamedFieldPuns. -RecordDotSyntaxFail12.hs:129:11: +RecordDotSyntaxFail12.hs:130:11: error: For this to work enable NamedFieldPuns. -RecordDotSyntaxFail12.hs:132:11: +RecordDotSyntaxFail12.hs:133:11: error: For this to work enable NamedFieldPuns. -RecordDotSyntaxFail12.hs:133:11: +RecordDotSyntaxFail12.hs:134:11: error: For this to work enable NamedFieldPuns. -RecordDotSyntaxFail12.hs:134:11: +RecordDotSyntaxFail12.hs:135:11: error: For this to work enable NamedFieldPuns. diff --git a/testsuite/tests/parser/should_fail/T12446.hs b/testsuite/tests/parser/should_fail/T12446.hs index 9f417e82dad5..83b0f4eecb4b 100644 --- a/testsuite/tests/parser/should_fail/T12446.hs +++ b/testsuite/tests/parser/should_fail/T12446.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module T12446 where x = undefined @(_ ~ _) diff --git a/testsuite/tests/parser/should_fail/T12446.stderr b/testsuite/tests/parser/should_fail/T12446.stderr index 8e5191382093..99a6f65e0b8f 100644 --- a/testsuite/tests/parser/should_fail/T12446.stderr +++ b/testsuite/tests/parser/should_fail/T12446.stderr @@ -1,4 +1,4 @@ -T12446.hs:3:5: error: +T12446.hs:4:5: error: Illegal visible type application ‘@(_ ~ _)’ Perhaps you intended to use TypeApplications diff --git a/testsuite/tests/parser/should_fail/T12811.hs b/testsuite/tests/parser/should_fail/T12811.hs index c82a830e65d9..8ef1fcf38304 100644 --- a/testsuite/tests/parser/should_fail/T12811.hs +++ b/testsuite/tests/parser/should_fail/T12811.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE RankNTypes #-} module Bug where diff --git a/testsuite/tests/parser/should_fail/T12811.stderr b/testsuite/tests/parser/should_fail/T12811.stderr index fab39d73cce6..3dbf6bc34289 100644 --- a/testsuite/tests/parser/should_fail/T12811.stderr +++ b/testsuite/tests/parser/should_fail/T12811.stderr @@ -1,7 +1,6 @@ -T12811.hs:4:15: error: +T12811.hs:5:15: error: Illegal operator ‘.’ in type ‘foral a . a’ Use TypeOperators to allow operators in types -T12811.hs:4:15: error: Not in scope: type constructor or class ‘.’ - +T12811.hs:5:15: error: Not in scope: type constructor or class ‘.’ diff --git a/testsuite/tests/parser/should_fail/T14588.hs b/testsuite/tests/parser/should_fail/T14588.hs index 8a0bcecd7b05..2c011c873d63 100644 --- a/testsuite/tests/parser/should_fail/T14588.hs +++ b/testsuite/tests/parser/should_fail/T14588.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module T14588 where main = print (let !x = 1 + 2 in x) diff --git a/testsuite/tests/parser/should_fail/T14588.stderr b/testsuite/tests/parser/should_fail/T14588.stderr index 2efd9561e8bf..d4bf50570393 100644 --- a/testsuite/tests/parser/should_fail/T14588.stderr +++ b/testsuite/tests/parser/should_fail/T14588.stderr @@ -1,4 +1,4 @@ -T14588.hs:3:19: error: +T14588.hs:4:19: error: Illegal bang-pattern (use BangPatterns): !x diff --git a/testsuite/tests/parser/should_fail/T16270.hs b/testsuite/tests/parser/should_fail/T16270.hs index 0147f9776aa3..4967eeb5cef2 100644 --- a/testsuite/tests/parser/should_fail/T16270.hs +++ b/testsuite/tests/parser/should_fail/T16270.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE NoTraditionalRecordSyntax, NoDoAndIfThenElse, NoMultiWayIf, NoLambdaCase, NoNumericUnderscores, MagicHash #-} {-# OPTIONS -Werror=missing-space-after-bang #-} diff --git a/testsuite/tests/parser/should_fail/T16270.stderr b/testsuite/tests/parser/should_fail/T16270.stderr index a74bdeb8f07e..6aecc3b264d7 100644 --- a/testsuite/tests/parser/should_fail/T16270.stderr +++ b/testsuite/tests/parser/should_fail/T16270.stderr @@ -1,71 +1,68 @@ -T16270.hs:2:12: warning: +T16270.hs:3:12: warning: -Werror=missing-space-after-bang is deprecated: bang patterns can no longer be written with a space -T16270.hs:7:1: warning: [-Wtabs (in -Wdefault)] +T16270.hs:8:1: warning: [-Wtabs (in -Wdefault)] Tab character found here, and in five further locations. Please use spaces instead. -T16270.hs:7:12: error: +T16270.hs:8:12: error: Unexpected semi-colons in conditional: if c then False; else True Perhaps you meant to use DoAndIfThenElse? -T16270.hs:12:8: error: +T16270.hs:13:8: error: Unexpected do block in function application: do 1 You could write it with parentheses Or perhaps you meant to enable BlockArguments? -T16270.hs:13:8: error: +T16270.hs:14:8: error: Unexpected lambda expression in function application: \ x -> x You could write it with parentheses Or perhaps you meant to enable BlockArguments? -T16270.hs:15:6: error: - Illegal datatype context (use DatatypeContexts): Num a => - -T16270.hs:17:22: error: +T16270.hs:18:22: error: Illegal record syntax (use TraditionalRecordSyntax): {fst :: a, snd :: b} -T16270.hs:18:5: error: +T16270.hs:19:5: error: Illegal record syntax (use TraditionalRecordSyntax): p {fst = 1, snd = True} -T16270.hs:20:6: error: +T16270.hs:21:6: error: Illegal symbol ‘forall’ in type Perhaps you intended to use RankNTypes or a similar language extension to enable explicit-forall syntax: forall <tvs>. <type> -T16270.hs:21:8: error: +T16270.hs:22:8: error: Unexpected semi-colons in conditional: if True; then (); else () Perhaps you meant to use DoAndIfThenElse? -T16270.hs:23:10: error: +T16270.hs:24:10: error: Illegal keyword 'where' in data declaration Perhaps you intended to use GADTs or a similar language extension to enable syntax: data T where -T16270.hs:25:12: error: +T16270.hs:26:12: error: Illegal bang-pattern (use BangPatterns): !i -T16270.hs:27:9: error: +T16270.hs:28:9: error: Multi-way if-expressions need MultiWayIf turned on -T16270.hs:29:9: error: +T16270.hs:30:9: error: Multi-way if-expressions need MultiWayIf turned on -T16270.hs:32:6: error: Illegal lambda-case (use LambdaCase) +T16270.hs:33:6: error: Illegal lambda-case (use LambdaCase) -T16270.hs:35:5: error: +T16270.hs:36:5: error: Use NumericUnderscores to allow underscores in integer literals -T16270.hs:37:5: error: +T16270.hs:38:5: error: primitive string literal must contain only characters <= '\xFF' -T16270.hs:43:1: error: +T16270.hs:44:1: error: parse error (possibly incorrect indentation or mismatched brackets) diff --git a/testsuite/tests/parser/should_fail/T17162.hs b/testsuite/tests/parser/should_fail/T17162.hs index 6419da7544aa..6137b0eb5d36 100644 --- a/testsuite/tests/parser/should_fail/T17162.hs +++ b/testsuite/tests/parser/should_fail/T17162.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} -- {-# LANGUAGE NoBangPatterns #-} module T17162 where diff --git a/testsuite/tests/parser/should_fail/T17162.stderr b/testsuite/tests/parser/should_fail/T17162.stderr index d621e08ccc17..ff6cfb99c42d 100644 --- a/testsuite/tests/parser/should_fail/T17162.stderr +++ b/testsuite/tests/parser/should_fail/T17162.stderr @@ -1,4 +1,4 @@ -T17162.hs:6:21: error: +T17162.hs:7:21: error: Illegal bang-pattern (use BangPatterns): !enc diff --git a/testsuite/tests/parser/should_fail/T18251c.hs b/testsuite/tests/parser/should_fail/T18251c.hs index da455fea643b..a726df66df04 100644 --- a/testsuite/tests/parser/should_fail/T18251c.hs +++ b/testsuite/tests/parser/should_fail/T18251c.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module T18251c where f = id @Int diff --git a/testsuite/tests/parser/should_fail/T18251c.stderr b/testsuite/tests/parser/should_fail/T18251c.stderr index 9a7c66f8f3fc..b4f667d5dde0 100644 --- a/testsuite/tests/parser/should_fail/T18251c.stderr +++ b/testsuite/tests/parser/should_fail/T18251c.stderr @@ -1,4 +1,4 @@ -T18251c.hs:3:5: error: +T18251c.hs:4:5: error: Illegal visible type application ‘@Int’ Perhaps you intended to use TypeApplications diff --git a/testsuite/tests/parser/should_fail/T3095.hs b/testsuite/tests/parser/should_fail/T3095.hs index 9c508eb81b17..9a748932197e 100644 --- a/testsuite/tests/parser/should_fail/T3095.hs +++ b/testsuite/tests/parser/should_fail/T3095.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE KindSignatures #-} -- #3095 module T3095 where diff --git a/testsuite/tests/parser/should_fail/T3095.stderr b/testsuite/tests/parser/should_fail/T3095.stderr index ea2ee44244cf..599579deb047 100644 --- a/testsuite/tests/parser/should_fail/T3095.stderr +++ b/testsuite/tests/parser/should_fail/T3095.stderr @@ -1,10 +1,10 @@ -T3095.hs:7:12: error: +T3095.hs:8:12: error: Illegal symbol ‘forall’ in type Perhaps you intended to use RankNTypes or a similar language extension to enable explicit-forall syntax: forall <tvs>. <type> -T3095.hs:7:12: error: +T3095.hs:8:12: error: Unexpected type ‘forall x. x :: Type’ In the class declaration for ‘Bla’ A class declaration should have form diff --git a/testsuite/tests/parser/should_fail/T8258NoGADTs.hs b/testsuite/tests/parser/should_fail/T8258NoGADTs.hs index 1080233bcda5..9ae035e7e76c 100644 --- a/testsuite/tests/parser/should_fail/T8258NoGADTs.hs +++ b/testsuite/tests/parser/should_fail/T8258NoGADTs.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module T8258NoGADTs where data T where diff --git a/testsuite/tests/parser/should_fail/T8258NoGADTs.stderr b/testsuite/tests/parser/should_fail/T8258NoGADTs.stderr index 35f530627473..ecf3f7e11ba7 100644 --- a/testsuite/tests/parser/should_fail/T8258NoGADTs.stderr +++ b/testsuite/tests/parser/should_fail/T8258NoGADTs.stderr @@ -1,5 +1,5 @@ -T8258NoGADTs.hs:3:8: error: +T8258NoGADTs.hs:4:8: error: Illegal keyword 'where' in data declaration Perhaps you intended to use GADTs or a similar language extension to enable syntax: data T where diff --git a/testsuite/tests/parser/should_fail/readFail036.hs b/testsuite/tests/parser/should_fail/readFail036.hs index 15afd980f8f2..af2d1b3d0cc8 100644 --- a/testsuite/tests/parser/should_fail/readFail036.hs +++ b/testsuite/tests/parser/should_fail/readFail036.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module Foo where import Data.Kind (Type) diff --git a/testsuite/tests/parser/should_fail/readFail036.stderr b/testsuite/tests/parser/should_fail/readFail036.stderr index a66afacacfbe..469f5fb985aa 100644 --- a/testsuite/tests/parser/should_fail/readFail036.stderr +++ b/testsuite/tests/parser/should_fail/readFail036.stderr @@ -1,5 +1,5 @@ -readFail036.hs:5:16: error: +readFail036.hs:6:16: error: Illegal kind signature: ‘Type’ Perhaps you intended to use KindSignatures In the data type declaration for ‘Foo’ diff --git a/testsuite/tests/parser/should_fail/readFail037.hs b/testsuite/tests/parser/should_fail/readFail037.hs index 499f5cc0f335..0155578c3e00 100644 --- a/testsuite/tests/parser/should_fail/readFail037.hs +++ b/testsuite/tests/parser/should_fail/readFail037.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module Foo where diff --git a/testsuite/tests/parser/should_fail/readFail037.stderr b/testsuite/tests/parser/should_fail/readFail037.stderr index 6b317eb05195..27e36ab3440f 100644 --- a/testsuite/tests/parser/should_fail/readFail037.stderr +++ b/testsuite/tests/parser/should_fail/readFail037.stderr @@ -1,5 +1,5 @@ -readFail037.hs:4:1: error: +readFail037.hs:5:1: error: • Too many parameters for class ‘Foo’ (Enable MultiParamTypeClasses to allow multi-parameter classes) • In the class declaration for ‘Foo’ diff --git a/testsuite/tests/parser/should_fail/readFail039.hs b/testsuite/tests/parser/should_fail/readFail039.hs index c6cbdb9968b3..4aa2ff8d7fe0 100644 --- a/testsuite/tests/parser/should_fail/readFail039.hs +++ b/testsuite/tests/parser/should_fail/readFail039.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module Foo where diff --git a/testsuite/tests/parser/should_fail/readFail039.stderr b/testsuite/tests/parser/should_fail/readFail039.stderr index be948f0a0797..0200cdabd6d8 100644 --- a/testsuite/tests/parser/should_fail/readFail039.stderr +++ b/testsuite/tests/parser/should_fail/readFail039.stderr @@ -1,6 +1,6 @@ -readFail039.hs:8:14: error: - Can't make a derived instance of ‘C Foo’: - ‘C’ is not a stock derivable class (Eq, Show, etc.) - Try GeneralizedNewtypeDeriving for GHC's newtype-deriving extension - In the newtype declaration for ‘Foo’ +readFail039.hs:9:14: error: + • Can't make a derived instance of ‘C Foo’: + ‘C’ is not a stock derivable class (Eq, Show, etc.) + Try GeneralizedNewtypeDeriving for GHC's newtype-deriving extension + • In the newtype declaration for ‘Foo’ diff --git a/testsuite/tests/parser/should_run/BinaryLiterals0.hs b/testsuite/tests/parser/should_run/BinaryLiterals0.hs index 7257445fbaaf..7dc44610a9b8 100644 --- a/testsuite/tests/parser/should_run/BinaryLiterals0.hs +++ b/testsuite/tests/parser/should_run/BinaryLiterals0.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} -- | Anti-Test for GHC 7.10+'s @BinaryLiterals@ extensions (see GHC #9224) -- -- NB: This code won't compile with -XBinaryLiterals enabled diff --git a/testsuite/tests/partial-sigs/should_compile/Meltdown.hs b/testsuite/tests/partial-sigs/should_compile/Meltdown.hs index 318dc2488d3c..a5acdc256cac 100644 --- a/testsuite/tests/partial-sigs/should_compile/Meltdown.hs +++ b/testsuite/tests/partial-sigs/should_compile/Meltdown.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE PartialTypeSignatures, ScopedTypeVariables, NamedWildCards #-} module Meltdown where diff --git a/testsuite/tests/partial-sigs/should_compile/Meltdown.stderr b/testsuite/tests/partial-sigs/should_compile/Meltdown.stderr index 9b0d449ca523..2791c29866d1 100644 --- a/testsuite/tests/partial-sigs/should_compile/Meltdown.stderr +++ b/testsuite/tests/partial-sigs/should_compile/Meltdown.stderr @@ -7,9 +7,9 @@ TYPE CONSTRUCTORS data type NukeMonad{3} :: * -> * -> * -> * roles phantom phantom phantom CLASS INSTANCES - instance Functor (NukeMonad a b) -- Defined at Meltdown.hs:8:10 + instance Functor (NukeMonad a b) -- Defined at Meltdown.hs:9:10 instance Applicative (NukeMonad a b) - -- Defined at Meltdown.hs:11:10 - instance Monad (NukeMonad a b) -- Defined at Meltdown.hs:15:10 + -- Defined at Meltdown.hs:12:10 + instance Monad (NukeMonad a b) -- Defined at Meltdown.hs:16:10 Dependent modules: [] -Dependent packages: [base-4.13.0.0, ghc-bignum-1.0, ghc-prim-0.7.0] +Dependent packages: [base-4.16.0.0, ghc-bignum-1.0, ghc-prim-0.8.0] diff --git a/testsuite/tests/partial-sigs/should_compile/NamedWildcardInTypeFamilyInstanceLHS.hs b/testsuite/tests/partial-sigs/should_compile/NamedWildcardInTypeFamilyInstanceLHS.hs index b171221058ce..ff7cc698bf64 100644 --- a/testsuite/tests/partial-sigs/should_compile/NamedWildcardInTypeFamilyInstanceLHS.hs +++ b/testsuite/tests/partial-sigs/should_compile/NamedWildcardInTypeFamilyInstanceLHS.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies, NamedWildCards #-} module NamedWildcardInTypeFamilyInstanceLHS where diff --git a/testsuite/tests/partial-sigs/should_compile/ScopedNamedWildcardsGood.hs b/testsuite/tests/partial-sigs/should_compile/ScopedNamedWildcardsGood.hs index f74df663690a..77f3ef89e27c 100644 --- a/testsuite/tests/partial-sigs/should_compile/ScopedNamedWildcardsGood.hs +++ b/testsuite/tests/partial-sigs/should_compile/ScopedNamedWildcardsGood.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE PartialTypeSignatures, NamedWildCards #-} module ScopedNamedWildcardsGood where diff --git a/testsuite/tests/partial-sigs/should_compile/T10403.hs b/testsuite/tests/partial-sigs/should_compile/T10403.hs index 661025480550..5a0bff0f3cb8 100644 --- a/testsuite/tests/partial-sigs/should_compile/T10403.hs +++ b/testsuite/tests/partial-sigs/should_compile/T10403.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE PartialTypeSignatures #-} {-# OPTIONS_GHC -fdefer-type-errors #-} module T10403 where diff --git a/testsuite/tests/partial-sigs/should_compile/T10403.stderr b/testsuite/tests/partial-sigs/should_compile/T10403.stderr index f3b6343893cb..e329410514aa 100644 --- a/testsuite/tests/partial-sigs/should_compile/T10403.stderr +++ b/testsuite/tests/partial-sigs/should_compile/T10403.stderr @@ -1,28 +1,28 @@ -T10403.hs:15:7: warning: [-Wpartial-type-signatures (in -Wdefault)] +T10403.hs:16:7: warning: [-Wpartial-type-signatures (in -Wdefault)] • Found extra-constraints wildcard standing for ‘Functor f’ Where: ‘f’ is a rigid type variable bound by the inferred type of h1 :: Functor f => (a -> a1) -> f a -> H f - at T10403.hs:17:1-41 + at T10403.hs:18:1-41 • In the type signature: h1 :: _ => _ -T10403.hs:15:12: warning: [-Wpartial-type-signatures (in -Wdefault)] +T10403.hs:16:12: warning: [-Wpartial-type-signatures (in -Wdefault)] • Found type wildcard ‘_’ standing for ‘(a -> a1) -> f a -> H f’ Where: ‘a1’, ‘a’, ‘f’ are rigid type variables bound by the inferred type of h1 :: Functor f => (a -> a1) -> f a -> H f - at T10403.hs:17:1-41 + at T10403.hs:18:1-41 • In the type signature: h1 :: _ => _ -T10403.hs:19:7: warning: [-Wpartial-type-signatures (in -Wdefault)] +T10403.hs:20:7: warning: [-Wpartial-type-signatures (in -Wdefault)] • Found type wildcard ‘_’ standing for ‘(a -> a1) -> B t0 a -> H (B t0)’ Where: ‘t0’ is an ambiguous type variable ‘a1’, ‘a’ are rigid type variables bound by the inferred type of h2 :: (a -> a1) -> B t0 a -> H (B t0) - at T10403.hs:22:1-41 + at T10403.hs:23:1-41 • In the type signature: h2 :: _ -T10403.hs:28:8: warning: [-Wdeferred-type-errors (in -Wdefault)] +T10403.hs:29:8: warning: [-Wdeferred-type-errors (in -Wdefault)] • Couldn't match type ‘t0’ with ‘t’ Expected: H (B t) Actual: H (B t0) @@ -30,8 +30,8 @@ T10403.hs:28:8: warning: [-Wdeferred-type-errors (in -Wdefault)] This (rigid, skolem) type variable is bound by the type signature for: app2 :: forall t. H (B t) - at T10403.hs:27:1-15 + at T10403.hs:28:1-15 • In the expression: h2 (H . I) (B ()) In an equation for ‘app2’: app2 = h2 (H . I) (B ()) • Relevant bindings include - app2 :: H (B t) (bound at T10403.hs:28:1) + app2 :: H (B t) (bound at T10403.hs:29:1) diff --git a/testsuite/tests/partial-sigs/should_fail/NamedWildcardsNotEnabled.hs b/testsuite/tests/partial-sigs/should_fail/NamedWildcardsNotEnabled.hs index a6ae0788c855..3a58678c8f25 100644 --- a/testsuite/tests/partial-sigs/should_fail/NamedWildcardsNotEnabled.hs +++ b/testsuite/tests/partial-sigs/should_fail/NamedWildcardsNotEnabled.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module NamedWildcardsNotEnabled where foo :: _a -> _b diff --git a/testsuite/tests/partial-sigs/should_fail/NamedWildcardsNotEnabled.stderr b/testsuite/tests/partial-sigs/should_fail/NamedWildcardsNotEnabled.stderr index bddc47006000..2fb55bfe2a83 100644 --- a/testsuite/tests/partial-sigs/should_fail/NamedWildcardsNotEnabled.stderr +++ b/testsuite/tests/partial-sigs/should_fail/NamedWildcardsNotEnabled.stderr @@ -1,24 +1,24 @@ -NamedWildcardsNotEnabled.hs:4:9: error: +NamedWildcardsNotEnabled.hs:5:9: error: • Couldn't match expected type ‘_b’ with actual type ‘Bool’ ‘_b’ is a rigid type variable bound by the type signature for: foo :: forall _a _b. _a -> _b - at NamedWildcardsNotEnabled.hs:3:1-15 + at NamedWildcardsNotEnabled.hs:4:1-15 • In the expression: not x In an equation for ‘foo’: foo x = not x • Relevant bindings include - foo :: _a -> _b (bound at NamedWildcardsNotEnabled.hs:4:1) + foo :: _a -> _b (bound at NamedWildcardsNotEnabled.hs:5:1) -NamedWildcardsNotEnabled.hs:4:13: error: +NamedWildcardsNotEnabled.hs:5:13: error: • Couldn't match expected type ‘Bool’ with actual type ‘_a’ ‘_a’ is a rigid type variable bound by the type signature for: foo :: forall _a _b. _a -> _b - at NamedWildcardsNotEnabled.hs:3:1-15 + at NamedWildcardsNotEnabled.hs:4:1-15 • In the first argument of ‘not’, namely ‘x’ In the expression: not x In an equation for ‘foo’: foo x = not x • Relevant bindings include - x :: _a (bound at NamedWildcardsNotEnabled.hs:4:5) - foo :: _a -> _b (bound at NamedWildcardsNotEnabled.hs:4:1) + x :: _a (bound at NamedWildcardsNotEnabled.hs:5:5) + foo :: _a -> _b (bound at NamedWildcardsNotEnabled.hs:5:1) diff --git a/testsuite/tests/partial-sigs/should_fail/T10615.hs b/testsuite/tests/partial-sigs/should_fail/T10615.hs index 6938736e02ad..32e87781ab8c 100644 --- a/testsuite/tests/partial-sigs/should_fail/T10615.hs +++ b/testsuite/tests/partial-sigs/should_fail/T10615.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE RankNTypes #-} module T10615 where diff --git a/testsuite/tests/partial-sigs/should_fail/T10615.stderr b/testsuite/tests/partial-sigs/should_fail/T10615.stderr index 9cd93c24a7a1..e9c048ce1673 100644 --- a/testsuite/tests/partial-sigs/should_fail/T10615.stderr +++ b/testsuite/tests/partial-sigs/should_fail/T10615.stderr @@ -1,36 +1,36 @@ -T10615.hs:4:7: error: +T10615.hs:5:7: error: • Found type wildcard ‘_’ standing for ‘w1’ Where: ‘w1’ is an ambiguous type variable To use the inferred type, enable PartialTypeSignatures • In the type ‘_ -> f’ In the type signature: f1 :: _ -> f -T10615.hs:5:6: error: +T10615.hs:6:6: error: • Couldn't match type ‘f’ with ‘b1 -> w1’ Expected: w1 -> f Actual: w1 -> b1 -> w1 ‘f’ is a rigid type variable bound by the inferred type of f1 :: w1 -> f - at T10615.hs:4:1-12 + at T10615.hs:5:1-12 • In the expression: const In an equation for ‘f1’: f1 = const - • Relevant bindings include f1 :: w1 -> f (bound at T10615.hs:5:1) + • Relevant bindings include f1 :: w1 -> f (bound at T10615.hs:6:1) -T10615.hs:7:7: error: +T10615.hs:8:7: error: • Found type wildcard ‘_’ standing for ‘w0’ Where: ‘w0’ is an ambiguous type variable To use the inferred type, enable PartialTypeSignatures • In the type ‘_ -> _f’ In the type signature: f2 :: _ -> _f -T10615.hs:8:6: error: +T10615.hs:9:6: error: • Couldn't match type ‘_f’ with ‘b0 -> w0’ Expected: w0 -> _f Actual: w0 -> b0 -> w0 ‘_f’ is a rigid type variable bound by the inferred type of f2 :: w0 -> _f - at T10615.hs:7:1-13 + at T10615.hs:8:1-13 • In the expression: const In an equation for ‘f2’: f2 = const - • Relevant bindings include f2 :: w0 -> _f (bound at T10615.hs:8:1) + • Relevant bindings include f2 :: w0 -> _f (bound at T10615.hs:9:1) diff --git a/testsuite/tests/partial-sigs/should_fail/T12634.hs b/testsuite/tests/partial-sigs/should_fail/T12634.hs index 36865ed83118..c5e3c5da369b 100644 --- a/testsuite/tests/partial-sigs/should_fail/T12634.hs +++ b/testsuite/tests/partial-sigs/should_fail/T12634.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE DataKinds #-} {-# LANGUAGE ScopedTypeVariables #-} diff --git a/testsuite/tests/partial-sigs/should_fail/T12634.stderr b/testsuite/tests/partial-sigs/should_fail/T12634.stderr index 42871101490b..ef0386784c75 100644 --- a/testsuite/tests/partial-sigs/should_fail/T12634.stderr +++ b/testsuite/tests/partial-sigs/should_fail/T12634.stderr @@ -1,10 +1,10 @@ -T12634.hs:14:58: error: +T12634.hs:15:58: error: • Expected a type, but ‘'(t, m, m', r)’ has kind ‘(k1 -> k2 -> *, k0, k1, k2)’ • In the first argument of ‘Bench’, namely ‘'(t, m, m', r)’ In the type ‘t m' r -> Bench '(t, m, m', r)’ In the type signature: - bench_twacePow :: forall t m m' r. - _ => t m' r -> Bench '(t, m, m', r) + bench_twacePow :: forall t m m' r. _ => + t m' r -> Bench '(t, m, m', r) diff --git a/testsuite/tests/patsyn/should_compile/T10997_1.hs b/testsuite/tests/patsyn/should_compile/T10997_1.hs index 4cc4b40eecb0..7855343d5ab9 100644 --- a/testsuite/tests/patsyn/should_compile/T10997_1.hs +++ b/testsuite/tests/patsyn/should_compile/T10997_1.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module T10997_1 where import T10997_1a diff --git a/testsuite/tests/patsyn/should_compile/T10997_1a.hs b/testsuite/tests/patsyn/should_compile/T10997_1a.hs index 11af525c533d..bf69c41fa3c2 100644 --- a/testsuite/tests/patsyn/should_compile/T10997_1a.hs +++ b/testsuite/tests/patsyn/should_compile/T10997_1a.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE PatternSynonyms, ViewPatterns, ConstraintKinds, TypeFamilies, PolyKinds, KindSignatures #-} module T10997_1a where diff --git a/testsuite/tests/patsyn/should_compile/T12698.hs b/testsuite/tests/patsyn/should_compile/T12698.hs index 68cd817677e3..bb2bccbb443a 100644 --- a/testsuite/tests/patsyn/should_compile/T12698.hs +++ b/testsuite/tests/patsyn/should_compile/T12698.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# Language ViewPatterns, TypeOperators, KindSignatures, PolyKinds, StandaloneDeriving, GADTs, RebindableSyntax, RankNTypes, LambdaCase, PatternSynonyms, TypeApplications #-} diff --git a/testsuite/tests/patsyn/should_compile/T14394.script b/testsuite/tests/patsyn/should_compile/T14394.script index 208df0ca3606..29f738bbbde3 100644 --- a/testsuite/tests/patsyn/should_compile/T14394.script +++ b/testsuite/tests/patsyn/should_compile/T14394.script @@ -1,3 +1,4 @@ +:set -XHaskell2010 :set -XPatternSynonyms -XGADTs -XViewPatterns -XScopedTypeVariables import Data.Type.Equality @@ -21,4 +22,4 @@ data S a where { MkS :: Ord a => a -> S a } pattern Bam x y <- (MkS (x::a), MkS (y::a)) :info Bam --- Expecting only one provided Ord constraint \ No newline at end of file +-- Expecting only one provided Ord constraint diff --git a/testsuite/tests/patsyn/should_compile/T14394.stdout b/testsuite/tests/patsyn/should_compile/T14394.stdout index 83e745c60a43..5838db9f43ac 100644 --- a/testsuite/tests/patsyn/should_compile/T14394.stdout +++ b/testsuite/tests/patsyn/should_compile/T14394.stdout @@ -1,10 +1,10 @@ pattern Foo :: () => (b ~ a) => a :~~: b - -- Defined at <interactive>:5:1 + -- Defined at <interactive>:6:1 pattern Bar :: forall {k1} {k2} {a :: k1} {b :: k2}. () => (k2 ~ k1, b ~~ a) => a :~~: b - -- Defined at <interactive>:11:1 + -- Defined at <interactive>:12:1 pattern Bam :: () => Ord a => a -> a -> (S a, S a) - -- Defined at <interactive>:21:1 + -- Defined at <interactive>:22:1 diff --git a/testsuite/tests/patsyn/should_fail/T14507.hs b/testsuite/tests/patsyn/should_fail/T14507.hs index 9599b73c7780..b803f5073496 100644 --- a/testsuite/tests/patsyn/should_fail/T14507.hs +++ b/testsuite/tests/patsyn/should_fail/T14507.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# Language PatternSynonyms, ViewPatterns, GADTs, ConstraintKinds, RankNTypes, PolyKinds, ScopedTypeVariables, DataKinds, TypeOperators, TypeApplications, TypeFamilies, TypeFamilyDependencies #-} diff --git a/testsuite/tests/patsyn/should_fail/T14507.stderr b/testsuite/tests/patsyn/should_fail/T14507.stderr index 1279ec1e4e2e..beeb4de6851c 100644 --- a/testsuite/tests/patsyn/should_fail/T14507.stderr +++ b/testsuite/tests/patsyn/should_fail/T14507.stderr @@ -1,5 +1,5 @@ -T14507.hs:20:9: error: +T14507.hs:21:9: error: • Iceland Jack! Iceland Jack! Stop torturing me! Pattern-bound variable x :: TypeRep a has a type that mentions pattern-bound coercion: co diff --git a/testsuite/tests/patsyn/should_fail/T15694.hs b/testsuite/tests/patsyn/should_fail/T15694.hs index 915ad7e7dd0f..44b3c7a8d658 100644 --- a/testsuite/tests/patsyn/should_fail/T15694.hs +++ b/testsuite/tests/patsyn/should_fail/T15694.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# Language RankNTypes, PatternSynonyms, TypeOperators, DataKinds, PolyKinds, KindSignatures, GADTs #-} module T15694 where diff --git a/testsuite/tests/patsyn/should_fail/T15694.stderr b/testsuite/tests/patsyn/should_fail/T15694.stderr index 2b0b7b77b19f..2c3421321c07 100644 --- a/testsuite/tests/patsyn/should_fail/T15694.stderr +++ b/testsuite/tests/patsyn/should_fail/T15694.stderr @@ -1,8 +1,8 @@ -T15694.hs:22:35: error: +T15694.hs:23:35: error: • Expected kind ‘k1 -> k0’, but ‘f a1’ has kind ‘ks’ ‘ks’ is a rigid type variable bound by an explicit forall ks k (f :: k -> ks) (a1 :: k) (ctx :: Ctx ks) (ks1 :: Type) k1 (a2 :: k1) (ctx1 :: Ctx ks1) a3 - at T15694.hs:18:30-31 + at T15694.hs:19:30-31 • In the first argument of ‘(~~)’, namely ‘f a1 a2’ diff --git a/testsuite/tests/patsyn/should_fail/T15695.hs b/testsuite/tests/patsyn/should_fail/T15695.hs index de8035c72823..ebccb8a02e1c 100644 --- a/testsuite/tests/patsyn/should_fail/T15695.hs +++ b/testsuite/tests/patsyn/should_fail/T15695.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# Language RankNTypes, PatternSynonyms, DataKinds, PolyKinds, GADTs, TypeOperators, MultiParamTypeClasses, TypeFamilies, TypeSynonymInstances, FlexibleInstances, InstanceSigs, FlexibleContexts #-} diff --git a/testsuite/tests/patsyn/should_fail/T15695.stderr b/testsuite/tests/patsyn/should_fail/T15695.stderr index 9418f15a713f..555c00436021 100644 --- a/testsuite/tests/patsyn/should_fail/T15695.stderr +++ b/testsuite/tests/patsyn/should_fail/T15695.stderr @@ -1,5 +1,5 @@ -T15695.hs:39:14: warning: [-Wdeferred-type-errors (in -Wdefault)] +T15695.hs:40:14: warning: [-Wdeferred-type-errors (in -Wdefault)] • Could not deduce: a2 ~ NA 'VO from the context: ((* -> * -> *) ~ (k -> k1 -> *), Either ~~ f, ctx ~~ (a2 ':&: (a3 ':&: 'E)), f a2 ~~ f1, f1 a3 ~~ a4) @@ -12,7 +12,7 @@ T15695.hs:39:14: warning: [-Wdeferred-type-errors (in -Wdefault)] f a1 ~~ f1, f1 a2 ~~ a3) => a3 -> ApplyT kind a b, in an equation for ‘from'’ - at T15695.hs:39:8-21 + at T15695.hs:40:8-21 Expected: a4 Actual: Either (NA 'VO) a3 ‘a2’ is a rigid type variable bound by @@ -25,15 +25,15 @@ T15695.hs:39:14: warning: [-Wdeferred-type-errors (in -Wdefault)] f a1 ~~ f1, f1 a2 ~~ a3) => a3 -> ApplyT kind a b, in an equation for ‘from'’ - at T15695.hs:39:8-21 + at T15695.hs:40:8-21 • In the pattern: Left a In the pattern: ASSO (Left a) In an equation for ‘from'’: from' (ASSO (Left a)) = Here (a :* Nil) • Relevant bindings include from' :: ApplyT (* -> * -> *) Either ctx -> NS (NP NA) '[ '[ 'VO]] - (bound at T15695.hs:39:1) + (bound at T15695.hs:40:1) -T15695.hs:40:33: warning: [-Wdeferred-type-errors (in -Wdefault)] +T15695.hs:41:33: warning: [-Wdeferred-type-errors (in -Wdefault)] • Couldn't match type: a0 : as0 with: '[] Expected: NS (NP NA) '[] @@ -44,4 +44,4 @@ T15695.hs:40:33: warning: [-Wdeferred-type-errors (in -Wdefault)] from' (ASSO (Right b)) = There (Here undefined) • Relevant bindings include from' :: ApplyT (* -> * -> *) Either ctx -> NS (NP NA) '[ '[ 'VO]] - (bound at T15695.hs:39:1) + (bound at T15695.hs:40:1) diff --git a/testsuite/tests/perf/compiler/T13056.hs b/testsuite/tests/perf/compiler/T13056.hs index f2dd040bdcd8..bc0b7894d92d 100644 --- a/testsuite/tests/perf/compiler/T13056.hs +++ b/testsuite/tests/perf/compiler/T13056.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE DeriveDataTypeable #-} {-# LANGUAGE DeriveGeneric #-} {-# LANGUAGE DeriveFunctor #-} diff --git a/testsuite/tests/perf/compiler/T14683.hs b/testsuite/tests/perf/compiler/T14683.hs index 41146c7f7064..157d0eb6c643 100644 --- a/testsuite/tests/perf/compiler/T14683.hs +++ b/testsuite/tests/perf/compiler/T14683.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# OPTIONS_GHC -w #-} {-# OPTIONS -XMagicHash -XBangPatterns #-} module Grammar where diff --git a/testsuite/tests/perf/compiler/T3064.hs b/testsuite/tests/perf/compiler/T3064.hs index 298a09cecf49..af3dc2cde7e7 100644 --- a/testsuite/tests/perf/compiler/T3064.hs +++ b/testsuite/tests/perf/compiler/T3064.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# OPTIONS_GHC -fno-warn-redundant-constraints #-} {-# LANGUAGE Rank2Types, TypeSynonymInstances, FlexibleInstances #-} {-# LANGUAGE TypeFamilies, GeneralizedNewtypeDeriving #-} diff --git a/testsuite/tests/perf/compiler/T9872a.hs b/testsuite/tests/perf/compiler/T9872a.hs index 7ceba4ee6689..8074cf98cd8b 100644 --- a/testsuite/tests/perf/compiler/T9872a.hs +++ b/testsuite/tests/perf/compiler/T9872a.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {- - Instant Insanity using Type Families. - diff --git a/testsuite/tests/perf/compiler/T9872a.stderr b/testsuite/tests/perf/compiler/T9872a.stderr index b38fcaeeb13d..067dc35606a1 100644 --- a/testsuite/tests/perf/compiler/T9872a.stderr +++ b/testsuite/tests/perf/compiler/T9872a.stderr @@ -1,5 +1,5 @@ -T9872a.hs:16:8: +T9872a.hs:17:8: No instance for (Show (Proxy (Cons diff --git a/testsuite/tests/perf/compiler/T9872c.hs b/testsuite/tests/perf/compiler/T9872c.hs index b925c9f791e8..dff3d792e8f9 100644 --- a/testsuite/tests/perf/compiler/T9872c.hs +++ b/testsuite/tests/perf/compiler/T9872c.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {- - Instant Insanity using Closed Type Families, but no DataKinds - diff --git a/testsuite/tests/perf/compiler/T9872c.stderr b/testsuite/tests/perf/compiler/T9872c.stderr index 121e54d48e67..5c22868ff27b 100644 --- a/testsuite/tests/perf/compiler/T9872c.stderr +++ b/testsuite/tests/perf/compiler/T9872c.stderr @@ -1,5 +1,5 @@ -T9872c.hs:17:8: +T9872c.hs:18:8: No instance for (Show (Proxy (Cons diff --git a/testsuite/tests/perf/should_run/T7257.hs b/testsuite/tests/perf/should_run/T7257.hs index 8907c3c918ea..17b103a3d8a1 100644 --- a/testsuite/tests/perf/should_run/T7257.hs +++ b/testsuite/tests/perf/should_run/T7257.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE BangPatterns #-} module Main where @@ -22,8 +23,8 @@ undo ref = do main = do ref <- newIORef [S.empty] let fn n = do - doStuff ref n - when (rem 5 n /= 0 ) $ undo ref + doStuff ref n + when (rem 5 n /= 0 ) $ undo ref mapM_ fn (take 5000000 $ cycle [1..100]) var <- readIORef ref diff --git a/testsuite/tests/plugins/FrontendPlugin.hs b/testsuite/tests/plugins/FrontendPlugin.hs index e264cc4062a0..7d5ed905e8b2 100644 --- a/testsuite/tests/plugins/FrontendPlugin.hs +++ b/testsuite/tests/plugins/FrontendPlugin.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE NondecreasingIndentation #-} module FrontendPlugin where import GHC.Plugins diff --git a/testsuite/tests/plugins/frontend01.hs b/testsuite/tests/plugins/frontend01.hs index db014568d4a2..e63c79b791d8 100644 --- a/testsuite/tests/plugins/frontend01.hs +++ b/testsuite/tests/plugins/frontend01.hs @@ -1 +1,2 @@ +{-# LANGUAGE Haskell2010 #-} main = putStrLn "hello world" diff --git a/testsuite/tests/pmcheck/complete_sigs/T14253.hs b/testsuite/tests/pmcheck/complete_sigs/T14253.hs index bb56d437bfe6..fc594b435555 100644 --- a/testsuite/tests/pmcheck/complete_sigs/T14253.hs +++ b/testsuite/tests/pmcheck/complete_sigs/T14253.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE GADTs #-} {-# LANGUAGE PatternSynonyms #-} {-# LANGUAGE TypeOperators #-} diff --git a/testsuite/tests/polykinds/BadKindVar.hs b/testsuite/tests/polykinds/BadKindVar.hs index 9275d453c593..760a9b1b3996 100644 --- a/testsuite/tests/polykinds/BadKindVar.hs +++ b/testsuite/tests/polykinds/BadKindVar.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE RankNTypes, KindSignatures #-} module Foo where diff --git a/testsuite/tests/polykinds/BadKindVar.stderr b/testsuite/tests/polykinds/BadKindVar.stderr index 33123506027b..19944a4df84c 100644 --- a/testsuite/tests/polykinds/BadKindVar.stderr +++ b/testsuite/tests/polykinds/BadKindVar.stderr @@ -1,5 +1,5 @@ -BadKindVar.hs:8:21: error: +BadKindVar.hs:9:21: error: Unexpected kind variable ‘k’ Perhaps you intended to use PolyKinds In the type signature for ‘f’ diff --git a/testsuite/tests/polykinds/NestedProxies.hs b/testsuite/tests/polykinds/NestedProxies.hs index d59d026544d5..a9873b01022d 100644 --- a/testsuite/tests/polykinds/NestedProxies.hs +++ b/testsuite/tests/polykinds/NestedProxies.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE KindSignatures #-} {-# LANGUAGE TypeFamilies #-} {-# LANGUAGE UndecidableInstances #-} diff --git a/testsuite/tests/polykinds/PolyKinds04.hs b/testsuite/tests/polykinds/PolyKinds04.hs index d3e1078c4fb5..fac9ff89637b 100644 --- a/testsuite/tests/polykinds/PolyKinds04.hs +++ b/testsuite/tests/polykinds/PolyKinds04.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module PolyKinds04 where diff --git a/testsuite/tests/polykinds/PolyKinds04.stderr b/testsuite/tests/polykinds/PolyKinds04.stderr index 2a8829162336..faa4f4cd692b 100644 --- a/testsuite/tests/polykinds/PolyKinds04.stderr +++ b/testsuite/tests/polykinds/PolyKinds04.stderr @@ -1,7 +1,7 @@ -PolyKinds04.hs:5:16: - Expecting one more argument to ‘Maybe’ - Expected a type, but ‘Maybe’ has kind ‘* -> *’ - In the first argument of ‘A’, namely ‘Maybe’ - In the type ‘(A Maybe)’ - In the definition of data constructor ‘B1’ +PolyKinds04.hs:6:16: error: + • Expecting one more argument to ‘Maybe’ + Expected a type, but ‘Maybe’ has kind ‘* -> *’ + • In the first argument of ‘A’, namely ‘Maybe’ + In the type ‘(A Maybe)’ + In the definition of data constructor ‘B1’ diff --git a/testsuite/tests/polykinds/T10670a.hs b/testsuite/tests/polykinds/T10670a.hs index d398cb72a898..489e1d56c579 100644 --- a/testsuite/tests/polykinds/T10670a.hs +++ b/testsuite/tests/polykinds/T10670a.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE GADTs , PolyKinds #-} module Bug2 where diff --git a/testsuite/tests/polykinds/T11362.hs b/testsuite/tests/polykinds/T11362.hs index d08ebe2461ff..7763cf460da9 100644 --- a/testsuite/tests/polykinds/T11362.hs +++ b/testsuite/tests/polykinds/T11362.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE DataKinds #-} {-# LANGUAGE PolyKinds #-} {-# LANGUAGE KindSignatures #-} diff --git a/testsuite/tests/polykinds/T11480a.hs b/testsuite/tests/polykinds/T11480a.hs index b491a215184e..26e53807b289 100644 --- a/testsuite/tests/polykinds/T11480a.hs +++ b/testsuite/tests/polykinds/T11480a.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# language KindSignatures, PolyKinds, TypeFamilies, NoImplicitPrelude, FlexibleContexts, MultiParamTypeClasses, GADTs, diff --git a/testsuite/tests/polykinds/T11480b.hs b/testsuite/tests/polykinds/T11480b.hs index 0ec19753a05d..a144c97a34e2 100644 --- a/testsuite/tests/polykinds/T11480b.hs +++ b/testsuite/tests/polykinds/T11480b.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# language KindSignatures #-} {-# language PolyKinds #-} {-# language DataKinds #-} diff --git a/testsuite/tests/polykinds/T11520.hs b/testsuite/tests/polykinds/T11520.hs index 9c1d4fe1be3f..18881f333f32 100644 --- a/testsuite/tests/polykinds/T11520.hs +++ b/testsuite/tests/polykinds/T11520.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE RankNTypes, PolyKinds, GADTs, UndecidableSuperClasses, UndecidableInstances #-} module T11520 where diff --git a/testsuite/tests/polykinds/T11520.stderr b/testsuite/tests/polykinds/T11520.stderr index 90a582626660..8b9ddb09a89a 100644 --- a/testsuite/tests/polykinds/T11520.stderr +++ b/testsuite/tests/polykinds/T11520.stderr @@ -1,9 +1,9 @@ -T11520.hs:15:77: error: +T11520.hs:16:77: error: • Expected kind ‘k2 -> k1’, but ‘g’ has kind ‘k4’ ‘k4’ is a rigid type variable bound by an instance declaration - at T11520.hs:15:10-78 + at T11520.hs:16:10-78 • In the second argument of ‘Compose’, namely ‘g’ In the first argument of ‘Typeable’, namely ‘(Compose f g)’ In the instance declaration for ‘Typeable (Compose f g)’ diff --git a/testsuite/tests/polykinds/T11523.hs b/testsuite/tests/polykinds/T11523.hs index aff0f9ed9048..97551b220897 100644 --- a/testsuite/tests/polykinds/T11523.hs +++ b/testsuite/tests/polykinds/T11523.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# language KindSignatures #-} {-# language PolyKinds #-} {-# language DataKinds #-} diff --git a/testsuite/tests/polykinds/T12055.hs b/testsuite/tests/polykinds/T12055.hs index cabc2dfbbac3..de3ad455ea26 100644 --- a/testsuite/tests/polykinds/T12055.hs +++ b/testsuite/tests/polykinds/T12055.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE ConstraintKinds #-} {-# LANGUAGE MultiParamTypeClasses #-} {-# LANGUAGE NoImplicitPrelude #-} diff --git a/testsuite/tests/polykinds/T12055a.hs b/testsuite/tests/polykinds/T12055a.hs index ebc4dc7cad16..e26da3246c59 100644 --- a/testsuite/tests/polykinds/T12055a.hs +++ b/testsuite/tests/polykinds/T12055a.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE ConstraintKinds #-} {-# LANGUAGE MultiParamTypeClasses #-} {-# LANGUAGE NoImplicitPrelude #-} diff --git a/testsuite/tests/polykinds/T12055a.stderr b/testsuite/tests/polykinds/T12055a.stderr index fb76dd4989a0..65d8b636ee53 100644 --- a/testsuite/tests/polykinds/T12055a.stderr +++ b/testsuite/tests/polykinds/T12055a.stderr @@ -1,5 +1,5 @@ -T12055a.hs:27:1: error: +T12055a.hs:28:1: error: • Non type-variable argument in the constraint: Category (Dom f) (Use FlexibleContexts to permit this) • In the context: (Category (Dom f), Category (Cod f)) diff --git a/testsuite/tests/polykinds/T14172.hs b/testsuite/tests/polykinds/T14172.hs index 06956be91a67..4089ea84db3e 100644 --- a/testsuite/tests/polykinds/T14172.hs +++ b/testsuite/tests/polykinds/T14172.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module T14172 where import Data.Functor.Compose diff --git a/testsuite/tests/polykinds/T14172.stderr b/testsuite/tests/polykinds/T14172.stderr index 3496b04538a9..2ad319592c4e 100644 --- a/testsuite/tests/polykinds/T14172.stderr +++ b/testsuite/tests/polykinds/T14172.stderr @@ -1,26 +1,26 @@ -T14172.hs:6:46: error: +T14172.hs:7:46: error: • Found type wildcard ‘_’ standing for ‘a'’ Where: ‘a'’ is a rigid type variable bound by the inferred type of traverseCompose :: (a -> f b) -> g a -> f (h a') - at T14172.hs:7:1-46 + at T14172.hs:8:1-46 To use the inferred type, enable PartialTypeSignatures • In the first argument of ‘h’, namely ‘_’ In the first argument of ‘f’, namely ‘(h _)’ In the type ‘(a -> f b) -> g a -> f (h _)’ -T14172.hs:7:19: error: +T14172.hs:8:19: error: • Couldn't match type ‘h’ with ‘Compose f'0 g'0’ arising from a use of ‘_Wrapping’ ‘h’ is a rigid type variable bound by the inferred type of traverseCompose :: (a -> f b) -> g a -> f (h a') - at T14172.hs:6:1-47 + at T14172.hs:7:1-47 • In the first argument of ‘(.)’, namely ‘_Wrapping Compose’ In the expression: _Wrapping Compose . traverse In an equation for ‘traverseCompose’: traverseCompose = _Wrapping Compose . traverse • Relevant bindings include traverseCompose :: (a -> f b) -> g a -> f (h a') - (bound at T14172.hs:7:1) + (bound at T14172.hs:8:1) diff --git a/testsuite/tests/polykinds/T14270.hs b/testsuite/tests/polykinds/T14270.hs index d578be344e64..efdc68cc5a79 100644 --- a/testsuite/tests/polykinds/T14270.hs +++ b/testsuite/tests/polykinds/T14270.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE ViewPatterns #-} {-# LANGUAGE TypeOperators #-} {-# LANGUAGE RankNTypes #-} diff --git a/testsuite/tests/polykinds/T14450.hs b/testsuite/tests/polykinds/T14450.hs index 8571829619a6..e660263b19d3 100644 --- a/testsuite/tests/polykinds/T14450.hs +++ b/testsuite/tests/polykinds/T14450.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# Language KindSignatures, TypeOperators, PolyKinds, TypeOperators, ConstraintKinds, TypeFamilies, DataKinds, GADTs, AllowAmbiguousTypes, InstanceSigs #-} diff --git a/testsuite/tests/polykinds/T14450.stderr b/testsuite/tests/polykinds/T14450.stderr index c631bade8779..0c5110a4428b 100644 --- a/testsuite/tests/polykinds/T14450.stderr +++ b/testsuite/tests/polykinds/T14450.stderr @@ -1,5 +1,5 @@ -T14450.hs:33:3: error: +T14450.hs:34:3: error: • Type indexes must match class instance head Expected: Dom @k @k (IddSym0 @k) Actual: Dom @(*) @(*) (IddSym0 @(*)) diff --git a/testsuite/tests/polykinds/T14710.hs b/testsuite/tests/polykinds/T14710.hs index 2fec10a7a16b..de34bc3e057e 100644 --- a/testsuite/tests/polykinds/T14710.hs +++ b/testsuite/tests/polykinds/T14710.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE KindSignatures #-} {-# LANGUAGE MultiParamTypeClasses #-} {-# LANGUAGE ScopedTypeVariables #-} diff --git a/testsuite/tests/polykinds/T14710.stderr b/testsuite/tests/polykinds/T14710.stderr index 0bbfb0d6413c..fa83a74fc839 100644 --- a/testsuite/tests/polykinds/T14710.stderr +++ b/testsuite/tests/polykinds/T14710.stderr @@ -1,30 +1,30 @@ -T14710.hs:9:21: error: +T14710.hs:10:21: error: Unexpected kind variable ‘a’ Perhaps you intended to use PolyKinds In a class method signature for ‘c1’ -T14710.hs:10:22: error: +T14710.hs:11:22: error: Unexpected kind variable ‘a’ Perhaps you intended to use PolyKinds In a class method signature for ‘c2’ -T14710.hs:15:23: error: +T14710.hs:16:23: error: Unexpected kind variable ‘a’ Perhaps you intended to use PolyKinds In the type signature for ‘g1’ -T14710.hs:18:24: error: +T14710.hs:19:24: error: Unexpected kind variable ‘a’ Perhaps you intended to use PolyKinds In the type signature for ‘g2’ -T14710.hs:21:31: error: +T14710.hs:22:31: error: Unexpected kind variable ‘k’ Perhaps you intended to use PolyKinds In the type signature for ‘h1’ -T14710.hs:24:22: error: +T14710.hs:25:22: error: Unexpected kind variable ‘k’ Perhaps you intended to use PolyKinds In the type signature for ‘h2’ diff --git a/testsuite/tests/polykinds/T15787.hs b/testsuite/tests/polykinds/T15787.hs index 85e737a479ea..fbe67f3356f3 100644 --- a/testsuite/tests/polykinds/T15787.hs +++ b/testsuite/tests/polykinds/T15787.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# Language RankNTypes #-} {-# Language TypeApplications #-} {-# Language DataKinds #-} diff --git a/testsuite/tests/polykinds/T15787.stderr b/testsuite/tests/polykinds/T15787.stderr index b22e6c7b5b1a..4ab01d58fc6c 100644 --- a/testsuite/tests/polykinds/T15787.stderr +++ b/testsuite/tests/polykinds/T15787.stderr @@ -1,9 +1,9 @@ -T15787.hs:15:14: error: +T15787.hs:16:14: error: • Expected a type, but ‘k’ has kind ‘ob1’ ‘ob1’ is a rigid type variable bound by the data constructor ‘Kl’ - at T15787.hs:15:3-43 + at T15787.hs:16:3-43 • In the type ‘k’ In the definition of data constructor ‘Kl’ In the data declaration for ‘Kl_kind’ diff --git a/testsuite/tests/polykinds/T16244.hs b/testsuite/tests/polykinds/T16244.hs index dbcb5232b4f8..9b29c2237ac5 100644 --- a/testsuite/tests/polykinds/T16244.hs +++ b/testsuite/tests/polykinds/T16244.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE ConstraintKinds #-} {-# LANGUAGE DataKinds #-} {-# LANGUAGE MultiParamTypeClasses #-} diff --git a/testsuite/tests/polykinds/T16244.stderr b/testsuite/tests/polykinds/T16244.stderr index 6b932ad285bb..4e83aa7b6f0c 100644 --- a/testsuite/tests/polykinds/T16244.stderr +++ b/testsuite/tests/polykinds/T16244.stderr @@ -1,11 +1,11 @@ -T16244.hs:11:18: error: +T16244.hs:12:18: error: • Expected kind ‘k’, but ‘b’ has kind ‘k1’ ‘k1’ is a rigid type variable bound by the class declaration for ‘C’ - at T16244.hs:11:26 + at T16244.hs:12:26 ‘k’ is a rigid type variable bound by the class declaration for ‘C’ - at T16244.hs:11:1-52 + at T16244.hs:12:1-52 • In the second argument of ‘SameKind’, namely ‘b’ In the class declaration for ‘C’ diff --git a/testsuite/tests/polykinds/T16245.hs b/testsuite/tests/polykinds/T16245.hs index 8fcd38cb77c9..ba8c6bd566e2 100644 --- a/testsuite/tests/polykinds/T16245.hs +++ b/testsuite/tests/polykinds/T16245.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE ConstraintKinds #-} {-# LANGUAGE DataKinds #-} {-# LANGUAGE PolyKinds #-} diff --git a/testsuite/tests/polykinds/T16245.stderr b/testsuite/tests/polykinds/T16245.stderr index 4f7cc415c209..36f9d487e2a0 100644 --- a/testsuite/tests/polykinds/T16245.stderr +++ b/testsuite/tests/polykinds/T16245.stderr @@ -1,11 +1,11 @@ -T16245.hs:11:36: error: +T16245.hs:12:36: error: • Expected kind ‘k’, but ‘b’ has kind ‘k1’ ‘k1’ is a rigid type variable bound by the class declaration for ‘C’ - at T16245.hs:11:45 + at T16245.hs:12:45 ‘k’ is a rigid type variable bound by the class declaration for ‘C’ - at T16245.hs:11:1-62 + at T16245.hs:12:1-62 • In the second argument of ‘SameKind’, namely ‘b’ In the class declaration for ‘C’ diff --git a/testsuite/tests/polykinds/T16245a.hs b/testsuite/tests/polykinds/T16245a.hs index d6497012613c..65d904f60953 100644 --- a/testsuite/tests/polykinds/T16245a.hs +++ b/testsuite/tests/polykinds/T16245a.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE RankNTypes #-} {-# LANGUAGE TypeInType #-} module Bug where diff --git a/testsuite/tests/polykinds/T16245a.stderr b/testsuite/tests/polykinds/T16245a.stderr index 6279ba18bb91..0023432858eb 100644 --- a/testsuite/tests/polykinds/T16245a.stderr +++ b/testsuite/tests/polykinds/T16245a.stderr @@ -1,12 +1,12 @@ -T16245a.hs:10:66: error: +T16245a.hs:11:66: error: • Expected kind ‘k’, but ‘b’ has kind ‘k1’ ‘k1’ is a rigid type variable bound by the data constructor ‘MkT’ - at T16245a.hs:10:12 + at T16245a.hs:11:12 ‘k’ is a rigid type variable bound by the data constructor ‘MkT’ - at T16245a.hs:10:1-67 + at T16245a.hs:11:1-67 • In the second argument of ‘SameKind’, namely ‘b’ In the type ‘(forall (b :: k). SameKind a b)’ In the definition of data constructor ‘MkT’ diff --git a/testsuite/tests/polykinds/T16762b.hs b/testsuite/tests/polykinds/T16762b.hs index cad6bff33f51..2aad708ef048 100644 --- a/testsuite/tests/polykinds/T16762b.hs +++ b/testsuite/tests/polykinds/T16762b.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE ExplicitForAll #-} {-# LANGUAGE StandaloneKindSignatures #-} module T16762b where diff --git a/testsuite/tests/polykinds/T16762b.stderr b/testsuite/tests/polykinds/T16762b.stderr index ffb29b70dce0..3da5c8885651 100644 --- a/testsuite/tests/polykinds/T16762b.stderr +++ b/testsuite/tests/polykinds/T16762b.stderr @@ -1,4 +1,4 @@ -T16762b.hs:7:11: error: +T16762b.hs:8:11: error: Illegal kind: forall k. Type Did you mean to enable PolyKinds? diff --git a/testsuite/tests/polykinds/T16902.hs b/testsuite/tests/polykinds/T16902.hs index 70fc7bd742af..0eb7229a9280 100644 --- a/testsuite/tests/polykinds/T16902.hs +++ b/testsuite/tests/polykinds/T16902.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE DataKinds #-} {-# LANGUAGE GADTs #-} {-# LANGUAGE PolyKinds #-} diff --git a/testsuite/tests/polykinds/T16902.stderr b/testsuite/tests/polykinds/T16902.stderr index 61d1b0a2aef3..69022b3a1a62 100644 --- a/testsuite/tests/polykinds/T16902.stderr +++ b/testsuite/tests/polykinds/T16902.stderr @@ -1,9 +1,9 @@ -T16902.hs:11:10: error: +T16902.hs:12:10: error: • Expected a type, but found something with kind ‘a’ ‘a’ is a rigid type variable bound by the data constructor ‘MkF’ - at T16902.hs:11:3-12 + at T16902.hs:12:3-12 • In the type ‘F a’ In the definition of data constructor ‘MkF’ In the data declaration for ‘F’ diff --git a/testsuite/tests/polykinds/T17841.hs b/testsuite/tests/polykinds/T17841.hs index c728a11f0222..24189a6e8403 100644 --- a/testsuite/tests/polykinds/T17841.hs +++ b/testsuite/tests/polykinds/T17841.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE PolyKinds #-} module T17841 where diff --git a/testsuite/tests/polykinds/T17841.stderr b/testsuite/tests/polykinds/T17841.stderr index 739e4f268061..878f30ae7a02 100644 --- a/testsuite/tests/polykinds/T17841.stderr +++ b/testsuite/tests/polykinds/T17841.stderr @@ -1,9 +1,9 @@ -T17841.hs:7:45: error: +T17841.hs:8:45: error: • Expected a type, but ‘t’ has kind ‘k’ ‘k’ is a rigid type variable bound by the class declaration for ‘Foo’ - at T17841.hs:7:12-17 + at T17841.hs:8:12-17 • In the kind ‘t’ In the first argument of ‘Proxy’, namely ‘(a :: t)’ In the type signature: foo :: Proxy (a :: t) diff --git a/testsuite/tests/polykinds/T6068.hs b/testsuite/tests/polykinds/T6068.hs index cce718e92fe0..745f9b92c121 100644 --- a/testsuite/tests/polykinds/T6068.hs +++ b/testsuite/tests/polykinds/T6068.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# OPTIONS_GHC -fno-warn-redundant-constraints #-} {-# LANGUAGE PolyKinds, DataKinds, TypeFamilies, GADTs, MultiParamTypeClasses, KindSignatures, FunctionalDependencies, FlexibleInstances, UndecidableInstances, ExistentialQuantification #-} diff --git a/testsuite/tests/polykinds/T6068.script b/testsuite/tests/polykinds/T6068.script index 6b34183986f1..52b610dfe5e4 100644 --- a/testsuite/tests/polykinds/T6068.script +++ b/testsuite/tests/polykinds/T6068.script @@ -1,2 +1,3 @@ +:set -XHaskell2010 :l T6068 :t exists Nothing diff --git a/testsuite/tests/polykinds/T6137.hs b/testsuite/tests/polykinds/T6137.hs index b3f0c02ba6ae..6b7ebc47cc46 100644 --- a/testsuite/tests/polykinds/T6137.hs +++ b/testsuite/tests/polykinds/T6137.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE DataKinds #-} {-# LANGUAGE PolyKinds #-} {-# LANGUAGE KindSignatures #-} diff --git a/testsuite/tests/polykinds/T7053.hs b/testsuite/tests/polykinds/T7053.hs index d45dbadaee3f..9540e71c422b 100644 --- a/testsuite/tests/polykinds/T7053.hs +++ b/testsuite/tests/polykinds/T7053.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE PolyKinds, GADTs #-} module T7053 where diff --git a/testsuite/tests/polykinds/T7053a.hs b/testsuite/tests/polykinds/T7053a.hs index d5ae04690b88..8b798d530e19 100644 --- a/testsuite/tests/polykinds/T7053a.hs +++ b/testsuite/tests/polykinds/T7053a.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE PolyKinds, GADTs #-} module T7053a where diff --git a/testsuite/tests/polykinds/T7224.hs b/testsuite/tests/polykinds/T7224.hs index a065bc849423..0283b4be3cc9 100644 --- a/testsuite/tests/polykinds/T7224.hs +++ b/testsuite/tests/polykinds/T7224.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE PolyKinds #-} module T7224 where diff --git a/testsuite/tests/polykinds/T7224.stderr b/testsuite/tests/polykinds/T7224.stderr index ca1f32c1c274..8a6be86ce07b 100644 --- a/testsuite/tests/polykinds/T7224.stderr +++ b/testsuite/tests/polykinds/T7224.stderr @@ -1,18 +1,18 @@ -T7224.hs:6:19: error: +T7224.hs:7:19: error: • Expected kind ‘i’, but ‘i’ has kind ‘*’ ‘i’ is a rigid type variable bound by the class declaration for ‘PMonad'’ - at T7224.hs:5:16-36 + at T7224.hs:6:16-36 • In the first argument of ‘m’, namely ‘i’ In the type signature: ret' :: a -> m i i a In the class declaration for ‘PMonad'’ -T7224.hs:7:14: error: +T7224.hs:8:14: error: • Expected kind ‘i’, but ‘i’ has kind ‘*’ ‘i’ is a rigid type variable bound by the class declaration for ‘PMonad'’ - at T7224.hs:5:16-36 + at T7224.hs:6:16-36 • In the first argument of ‘m’, namely ‘i’ In the type signature: bind' :: m i j a -> (a -> m j k b) -> m i k b diff --git a/testsuite/tests/polykinds/T7805.hs b/testsuite/tests/polykinds/T7805.hs index 914200b27f04..ca1c2ee8b9e3 100644 --- a/testsuite/tests/polykinds/T7805.hs +++ b/testsuite/tests/polykinds/T7805.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE DataKinds, RankNTypes, TypeFamilies #-} module T7805 where diff --git a/testsuite/tests/polykinds/T7805.stderr b/testsuite/tests/polykinds/T7805.stderr index e4fdff52e0f1..cb87c5af6e39 100644 --- a/testsuite/tests/polykinds/T7805.stderr +++ b/testsuite/tests/polykinds/T7805.stderr @@ -1,5 +1,5 @@ -T7805.hs:7:21: error: +T7805.hs:8:21: error: • Expected kind ‘forall a. a -> a’, but ‘x’ has kind ‘*’ • In the first argument of ‘HR’, namely ‘x’ In the first argument of ‘F’, namely ‘(HR x)’ diff --git a/testsuite/tests/polykinds/T9200.hs b/testsuite/tests/polykinds/T9200.hs index 63c934c91b90..96edb604adc7 100644 --- a/testsuite/tests/polykinds/T9200.hs +++ b/testsuite/tests/polykinds/T9200.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE PolyKinds, MultiParamTypeClasses, FlexibleContexts, DataKinds, TypeFamilies #-} diff --git a/testsuite/tests/polykinds/TidyClassKinds.hs b/testsuite/tests/polykinds/TidyClassKinds.hs index 83f6eaaea2eb..632856530879 100644 --- a/testsuite/tests/polykinds/TidyClassKinds.hs +++ b/testsuite/tests/polykinds/TidyClassKinds.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE MultiParamTypeClasses, PolyKinds #-} {-# OPTIONS_GHC -fprint-explicit-kinds #-} diff --git a/testsuite/tests/polykinds/TidyClassKinds.stderr b/testsuite/tests/polykinds/TidyClassKinds.stderr index eb51ca56926a..eb626c446173 100644 --- a/testsuite/tests/polykinds/TidyClassKinds.stderr +++ b/testsuite/tests/polykinds/TidyClassKinds.stderr @@ -1,5 +1,5 @@ -TidyClassKinds.hs:12:10: error: +TidyClassKinds.hs:13:10: error: • Illegal instance declaration for ‘Poly @{k -> *} @{k -> *} (ProxySyn @{k}) (ProxySyn @{k})’ (All instance types must be of the form (T t1 ... tn) diff --git a/testsuite/tests/primops/should_compile/T16293a.hs b/testsuite/tests/primops/should_compile/T16293a.hs index 69368c70b5a2..41f8a63b74a2 100644 --- a/testsuite/tests/primops/should_compile/T16293a.hs +++ b/testsuite/tests/primops/should_compile/T16293a.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE MagicHash #-} {-# LANGUAGE TypeApplications #-} module T16293a where diff --git a/testsuite/tests/quantified-constraints/T15359.hs b/testsuite/tests/quantified-constraints/T15359.hs index 7ef1cc557281..2a58d89c05ec 100644 --- a/testsuite/tests/quantified-constraints/T15359.hs +++ b/testsuite/tests/quantified-constraints/T15359.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE MultiParamTypeClasses, GADTs, RankNTypes, ConstraintKinds, QuantifiedConstraints #-} diff --git a/testsuite/tests/quantified-constraints/T15359a.hs b/testsuite/tests/quantified-constraints/T15359a.hs index 6ec5f861a8ea..a5b16acf7553 100644 --- a/testsuite/tests/quantified-constraints/T15359a.hs +++ b/testsuite/tests/quantified-constraints/T15359a.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE MultiParamTypeClasses, GADTs, RankNTypes, ConstraintKinds, QuantifiedConstraints, UndecidableInstances #-} diff --git a/testsuite/tests/quantified-constraints/T18432.hs b/testsuite/tests/quantified-constraints/T18432.hs index ba5072742064..6c02887ba7e8 100644 --- a/testsuite/tests/quantified-constraints/T18432.hs +++ b/testsuite/tests/quantified-constraints/T18432.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE QuantifiedConstraints #-} module Bug where diff --git a/testsuite/tests/rename/should_compile/T1972.hs b/testsuite/tests/rename/should_compile/T1972.hs index 7b6d7387c769..f4067cd1d5d5 100644 --- a/testsuite/tests/rename/should_compile/T1972.hs +++ b/testsuite/tests/rename/should_compile/T1972.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# OPTIONS_GHC -fwarn-name-shadowing -fwarn-unused-binds #-} -- #1972 diff --git a/testsuite/tests/rename/should_compile/T1972.stderr b/testsuite/tests/rename/should_compile/T1972.stderr index 78f58b54157f..3311f0adedf5 100644 --- a/testsuite/tests/rename/should_compile/T1972.stderr +++ b/testsuite/tests/rename/should_compile/T1972.stderr @@ -1,13 +1,13 @@ -T1972.hs:12:3: warning: [-Wname-shadowing (in -Wall)] +T1972.hs:13:3: warning: [-Wname-shadowing (in -Wall)] This binding for ‘name’ shadows the existing binding - defined at T1972.hs:9:19 + defined at T1972.hs:10:19 -T1972.hs:14:3: warning: [-Wname-shadowing (in -Wall)] +T1972.hs:15:3: warning: [-Wname-shadowing (in -Wall)] This binding for ‘mapAccumL’ shadows the existing bindings - imported from ‘Data.List’ at T1972.hs:7:19-27 + imported from ‘Data.List’ at T1972.hs:8:19-27 (and originally defined in ‘Data.Traversable’) - defined at T1972.hs:16:1 + defined at T1972.hs:17:1 -T1972.hs:20:10: warning: [-Wunused-local-binds (in -Wextra, -Wunused-binds)] +T1972.hs:21:10: warning: [-Wunused-local-binds (in -Wextra, -Wunused-binds)] Defined but not used: ‘c’ diff --git a/testsuite/tests/rename/should_compile/T4003A.hs-boot b/testsuite/tests/rename/should_compile/T4003A.hs-boot index 04902ddc62d1..329fd32aef0d 100644 --- a/testsuite/tests/rename/should_compile/T4003A.hs-boot +++ b/testsuite/tests/rename/should_compile/T4003A.hs-boot @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module T4003A where import Data.Data diff --git a/testsuite/tests/rename/should_compile/T4003B.hs b/testsuite/tests/rename/should_compile/T4003B.hs index 24ce2432a2fc..01c23b75977d 100644 --- a/testsuite/tests/rename/should_compile/T4003B.hs +++ b/testsuite/tests/rename/should_compile/T4003B.hs @@ -1,4 +1,4 @@ - +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE DeriveDataTypeable #-} module T4003B where diff --git a/testsuite/tests/rename/should_fail/RnFail055.hs b/testsuite/tests/rename/should_fail/RnFail055.hs index bd95add36b11..b71d0a7c3ae5 100644 --- a/testsuite/tests/rename/should_fail/RnFail055.hs +++ b/testsuite/tests/rename/should_fail/RnFail055.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE MultiParamTypeClasses,RankNTypes,ExistentialQuantification,DatatypeContexts #-} module RnFail055 where diff --git a/testsuite/tests/rename/should_fail/RnFail055.hs-boot b/testsuite/tests/rename/should_fail/RnFail055.hs-boot index 57a97d3695dc..ae2e81db21fb 100644 --- a/testsuite/tests/rename/should_fail/RnFail055.hs-boot +++ b/testsuite/tests/rename/should_fail/RnFail055.hs-boot @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE MultiParamTypeClasses,RankNTypes,ExistentialQuantification,DatatypeContexts #-} module RnFail055 where diff --git a/testsuite/tests/rename/should_fail/T11663.hs b/testsuite/tests/rename/should_fail/T11663.hs index 2b8380fba1b2..318f89e670c8 100644 --- a/testsuite/tests/rename/should_fail/T11663.hs +++ b/testsuite/tests/rename/should_fail/T11663.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module T11663 where -- All of these should fail as type signatures are not allowed diff --git a/testsuite/tests/rename/should_fail/T11663.stderr b/testsuite/tests/rename/should_fail/T11663.stderr index 18ee6e62d184..77e2999cece7 100644 --- a/testsuite/tests/rename/should_fail/T11663.stderr +++ b/testsuite/tests/rename/should_fail/T11663.stderr @@ -1,16 +1,16 @@ -T11663.hs:5:12: error: +T11663.hs:6:12: error: Illegal type signature: ‘Int’ Type signatures are only allowed in patterns with ScopedTypeVariables -T11663.hs:6:9: error: +T11663.hs:7:9: error: Illegal type signature: ‘Int’ Type signatures are only allowed in patterns with ScopedTypeVariables -T11663.hs:7:22: error: +T11663.hs:8:22: error: Illegal type signature: ‘Int’ Type signatures are only allowed in patterns with ScopedTypeVariables -T11663.hs:8:32: error: +T11663.hs:9:32: error: Illegal type signature: ‘Int’ Type signatures are only allowed in patterns with ScopedTypeVariables diff --git a/testsuite/tests/rename/should_fail/T3265.hs b/testsuite/tests/rename/should_fail/T3265.hs index 8e34fc2849ca..a04fffb8cdcd 100644 --- a/testsuite/tests/rename/should_fail/T3265.hs +++ b/testsuite/tests/rename/should_fail/T3265.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE MultiParamTypeClasses #-} -- Test #3265 diff --git a/testsuite/tests/rename/should_fail/T3265.stderr b/testsuite/tests/rename/should_fail/T3265.stderr index 999b6b3ed2bb..42d89d0b4e87 100644 --- a/testsuite/tests/rename/should_fail/T3265.stderr +++ b/testsuite/tests/rename/should_fail/T3265.stderr @@ -1,8 +1,8 @@ -T3265.hs:7:8: +T3265.hs:8:8: error: Illegal declaration of a type or class operator ‘:+:’ Use TypeOperators to declare operators in type and declarations -T3265.hs:9:9: +T3265.hs:10:9: error: Illegal declaration of a type or class operator ‘:*:’ Use TypeOperators to declare operators in type and declarations diff --git a/testsuite/tests/rename/should_fail/rnfail052.hs b/testsuite/tests/rename/should_fail/rnfail052.hs index bffb7e0d963a..a3fc361432df 100644 --- a/testsuite/tests/rename/should_fail/rnfail052.hs +++ b/testsuite/tests/rename/should_fail/rnfail052.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} -- Error messages when you use 'forall' *without* the RankN flags -- Test cases similar to #2114 diff --git a/testsuite/tests/rename/should_fail/rnfail052.stderr b/testsuite/tests/rename/should_fail/rnfail052.stderr index b8501cfad17c..b818a4b6bee0 100644 --- a/testsuite/tests/rename/should_fail/rnfail052.stderr +++ b/testsuite/tests/rename/should_fail/rnfail052.stderr @@ -1,15 +1,15 @@ -rnfail052.hs:6:6: error: +rnfail052.hs:7:6: error: Illegal symbol ‘forall’ in type Perhaps you intended to use RankNTypes or a similar language extension to enable explicit-forall syntax: forall <tvs>. <type> -rnfail052.hs:9:14: error: +rnfail052.hs:10:14: error: Illegal symbol ‘forall’ in type Perhaps you intended to use RankNTypes or a similar language extension to enable explicit-forall syntax: forall <tvs>. <type> -rnfail052.hs:12:15: error: +rnfail052.hs:13:15: error: Illegal symbol ‘forall’ in type Perhaps you intended to use RankNTypes or a similar language extension to enable explicit-forall syntax: forall <tvs>. <type> diff --git a/testsuite/tests/rename/should_fail/rnfail053.hs b/testsuite/tests/rename/should_fail/rnfail053.hs index 1135f42b8aa5..6250b5d1817e 100644 --- a/testsuite/tests/rename/should_fail/rnfail053.hs +++ b/testsuite/tests/rename/should_fail/rnfail053.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} -- Test #2114 (error message) module ShouldFail where diff --git a/testsuite/tests/rename/should_fail/rnfail053.stderr b/testsuite/tests/rename/should_fail/rnfail053.stderr index ab96278504ad..4d438c3821e9 100644 --- a/testsuite/tests/rename/should_fail/rnfail053.stderr +++ b/testsuite/tests/rename/should_fail/rnfail053.stderr @@ -1,5 +1,5 @@ -rnfail053.hs:5:10: error: +rnfail053.hs:6:10: error: • Data constructor ‘MkT’ has existential type variables, a context, or a specialised result type MkT :: forall a. a -> T (Enable ExistentialQuantification or GADTs to allow this) diff --git a/testsuite/tests/rename/should_fail/rnfail055.stderr b/testsuite/tests/rename/should_fail/rnfail055.stderr index ef4b09fd3a86..28b20d989a78 100644 --- a/testsuite/tests/rename/should_fail/rnfail055.stderr +++ b/testsuite/tests/rename/should_fail/rnfail055.stderr @@ -1,18 +1,18 @@ -RnFail055.hs:1:73: warning: +RnFail055.hs:2:73: warning: -XDatatypeContexts is deprecated: It was widely considered a misfeature, and has been removed from the Haskell language. -RnFail055.hs-boot:1:73: warning: +RnFail055.hs-boot:2:73: warning: -XDatatypeContexts is deprecated: It was widely considered a misfeature, and has been removed from the Haskell language. -RnFail055.hs-boot:4:1: error: +RnFail055.hs-boot:5:1: error: Identifier ‘f1’ has conflicting definitions in the module and its hs-boot file Main module: f1 :: Int -> Float Boot file: f1 :: Float -> Int The two types are different -RnFail055.hs-boot:6:1: error: +RnFail055.hs-boot:7:1: error: Type constructor ‘S1’ has conflicting definitions in the module and its hs-boot file Main module: type S1 :: * -> * -> * @@ -21,7 +21,7 @@ RnFail055.hs-boot:6:1: error: type S1 a b c = (a, b) The types have different kinds -RnFail055.hs-boot:8:1: error: +RnFail055.hs-boot:9:1: error: Type constructor ‘S2’ has conflicting definitions in the module and its hs-boot file Main module: type S2 :: * -> * -> * @@ -31,7 +31,7 @@ RnFail055.hs-boot:8:1: error: The roles do not match. Roles on abstract types default to ‘representational’ in boot files. -RnFail055.hs-boot:12:1: error: +RnFail055.hs-boot:13:1: error: Type constructor ‘T1’ has conflicting definitions in the module and its hs-boot file Main module: type T1 :: * -> * -> * @@ -40,7 +40,7 @@ RnFail055.hs-boot:12:1: error: data T1 a b = T1 [a] [b] The constructors do not match: The types for ‘T1’ differ -RnFail055.hs-boot:14:1: error: +RnFail055.hs-boot:15:1: error: Type constructor ‘T2’ has conflicting definitions in the module and its hs-boot file Main module: type role T2 representational nominal @@ -53,13 +53,13 @@ RnFail055.hs-boot:14:1: error: Roles on abstract types default to ‘representational’ in boot files. The datatype contexts do not match -RnFail055.hs-boot:16:11: error: +RnFail055.hs-boot:17:11: error: ‘T3’ is exported by the hs-boot file, but not exported by the module -RnFail055.hs-boot:17:12: error: +RnFail055.hs-boot:18:12: error: ‘T3'’ is exported by the hs-boot file, but not exported by the module -RnFail055.hs-boot:21:1: error: +RnFail055.hs-boot:22:1: error: Type constructor ‘T5’ has conflicting definitions in the module and its hs-boot file Main module: type T5 :: * -> * @@ -69,7 +69,7 @@ RnFail055.hs-boot:21:1: error: The constructors do not match: The record label lists for ‘T5’ differ -RnFail055.hs-boot:23:1: error: +RnFail055.hs-boot:24:1: error: Type constructor ‘T6’ has conflicting definitions in the module and its hs-boot file Main module: type T6 :: * @@ -79,7 +79,7 @@ RnFail055.hs-boot:23:1: error: The constructors do not match: The strictness annotations for ‘T6’ differ -RnFail055.hs-boot:25:1: error: +RnFail055.hs-boot:26:1: error: Type constructor ‘T7’ has conflicting definitions in the module and its hs-boot file Main module: type role T7 phantom @@ -91,10 +91,10 @@ RnFail055.hs-boot:25:1: error: Roles on abstract types default to ‘representational’ in boot files. The constructors do not match: The types for ‘T7’ differ -RnFail055.hs-boot:27:22: error: +RnFail055.hs-boot:28:22: error: ‘RnFail055.m1’ is exported by the hs-boot file, but not exported by the module -RnFail055.hs-boot:28:1: error: +RnFail055.hs-boot:29:1: error: Class ‘C2’ has conflicting definitions in the module and its hs-boot file Main module: type C2 :: * -> * -> Constraint @@ -109,7 +109,7 @@ RnFail055.hs-boot:28:1: error: The methods do not match: There are different numbers of methods The MINIMAL pragmas are not compatible -RnFail055.hs-boot:29:1: error: +RnFail055.hs-boot:30:1: error: Class ‘C3’ has conflicting definitions in the module and its hs-boot file Main module: type C3 :: * -> Constraint diff --git a/testsuite/tests/rename/should_fail/rnfail056.hs b/testsuite/tests/rename/should_fail/rnfail056.hs index 23ec008dc6e8..f41baec38e75 100644 --- a/testsuite/tests/rename/should_fail/rnfail056.hs +++ b/testsuite/tests/rename/should_fail/rnfail056.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} -- TupleSections not enabled {-# LANGUAGE UnboxedTuples #-} diff --git a/testsuite/tests/rename/should_fail/rnfail056.stderr b/testsuite/tests/rename/should_fail/rnfail056.stderr index 19c1188ce413..b32a31d58c4d 100644 --- a/testsuite/tests/rename/should_fail/rnfail056.stderr +++ b/testsuite/tests/rename/should_fail/rnfail056.stderr @@ -1,4 +1,4 @@ -rnfail056.hs:6:7: Illegal tuple section: use TupleSections +rnfail056.hs:7:7: error: Illegal tuple section: use TupleSections -rnfail056.hs:8:7: Illegal tuple section: use TupleSections +rnfail056.hs:9:7: error: Illegal tuple section: use TupleSections diff --git a/testsuite/tests/roles/should_compile/Roles3.hs b/testsuite/tests/roles/should_compile/Roles3.hs index 3df74ec8e294..b71d9cf2eceb 100644 --- a/testsuite/tests/roles/should_compile/Roles3.hs +++ b/testsuite/tests/roles/should_compile/Roles3.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies, MultiParamTypeClasses #-} {-# LANGUAGE AllowAmbiguousTypes #-} -- meth3, meth4 are ambiguous diff --git a/testsuite/tests/roles/should_compile/T8958.hs b/testsuite/tests/roles/should_compile/T8958.hs index b3c2910e2ec7..e4bf28f1aaaf 100644 --- a/testsuite/tests/roles/should_compile/T8958.hs +++ b/testsuite/tests/roles/should_compile/T8958.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE RoleAnnotations, DatatypeContexts, IncoherentInstances, FlexibleInstances #-} diff --git a/testsuite/tests/roles/should_compile/T8958.stderr b/testsuite/tests/roles/should_compile/T8958.stderr index 203f978daa32..6cf07483d009 100644 --- a/testsuite/tests/roles/should_compile/T8958.stderr +++ b/testsuite/tests/roles/should_compile/T8958.stderr @@ -1,5 +1,5 @@ -T8958.hs:1:31: warning: +T8958.hs:2:31: warning: -XDatatypeContexts is deprecated: It was widely considered a misfeature, and has been removed from the Haskell language. TYPE CONSTRUCTORS newtype Map{2} :: * -> * -> * @@ -13,10 +13,10 @@ DATA CONSTRUCTORS MkMap :: forall k v. [(k, v)] -> Map k v CLASS INSTANCES instance [incoherent] Representational a - -- Defined at T8958.hs:10:10 - instance [incoherent] Nominal a -- Defined at T8958.hs:7:10 + -- Defined at T8958.hs:11:10 + instance [incoherent] Nominal a -- Defined at T8958.hs:8:10 Dependent modules: [] -Dependent packages: [base-4.15.0.0, ghc-bignum-1.0, ghc-prim-0.7.0] +Dependent packages: [base-4.16.0.0, ghc-bignum-1.0, ghc-prim-0.8.0] ==================== Typechecker ==================== T8958.$tcMap diff --git a/testsuite/tests/roles/should_fail/Roles12.hs b/testsuite/tests/roles/should_fail/Roles12.hs index 0942a0be414d..a31bf6534c5a 100644 --- a/testsuite/tests/roles/should_fail/Roles12.hs +++ b/testsuite/tests/roles/should_fail/Roles12.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module Roles12 where import Roles12a diff --git a/testsuite/tests/roles/should_fail/Roles12.hs-boot b/testsuite/tests/roles/should_fail/Roles12.hs-boot index 6a708d984ac4..a78daefb53d9 100644 --- a/testsuite/tests/roles/should_fail/Roles12.hs-boot +++ b/testsuite/tests/roles/should_fail/Roles12.hs-boot @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module Roles12 where -data T a \ No newline at end of file +data T a diff --git a/testsuite/tests/roles/should_fail/Roles12.stderr b/testsuite/tests/roles/should_fail/Roles12.stderr index ec3bff418214..b4d7499fe94f 100644 --- a/testsuite/tests/roles/should_fail/Roles12.stderr +++ b/testsuite/tests/roles/should_fail/Roles12.stderr @@ -1,5 +1,5 @@ -Roles12.hs:5:1: error: +Roles12.hs:6:1: error: Type constructor ‘T’ has conflicting definitions in the module and its hs-boot file Main module: type role T phantom diff --git a/testsuite/tests/roles/should_fail/Roles12a.hs b/testsuite/tests/roles/should_fail/Roles12a.hs index a7c02c5fcd6c..3a00c4f635f1 100644 --- a/testsuite/tests/roles/should_fail/Roles12a.hs +++ b/testsuite/tests/roles/should_fail/Roles12a.hs @@ -1,2 +1,3 @@ +{-# LANGUAGE Haskell2010 #-} module Roles12a where import {-# SOURCE #-} Roles12 diff --git a/testsuite/tests/roles/should_fail/T9204.hs b/testsuite/tests/roles/should_fail/T9204.hs index 52befcac2077..fe2c81121ed5 100644 --- a/testsuite/tests/roles/should_fail/T9204.hs +++ b/testsuite/tests/roles/should_fail/T9204.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module T9204 where diff --git a/testsuite/tests/roles/should_fail/T9204.hs-boot b/testsuite/tests/roles/should_fail/T9204.hs-boot index 7ee0f1db3e42..3606c82d7ecb 100644 --- a/testsuite/tests/roles/should_fail/T9204.hs-boot +++ b/testsuite/tests/roles/should_fail/T9204.hs-boot @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module T9204 where diff --git a/testsuite/tests/roles/should_fail/T9204.stderr b/testsuite/tests/roles/should_fail/T9204.stderr index 0e8cbf452427..c54df4870c64 100644 --- a/testsuite/tests/roles/should_fail/T9204.stderr +++ b/testsuite/tests/roles/should_fail/T9204.stderr @@ -1,5 +1,5 @@ -T9204.hs:6:1: error: +T9204.hs:7:1: error: Type constructor ‘D’ has conflicting definitions in the module and its hs-boot file Main module: type role D phantom diff --git a/testsuite/tests/roles/should_fail/T9204a.hs b/testsuite/tests/roles/should_fail/T9204a.hs index a57e2b28a21b..a290f1a1bf61 100644 --- a/testsuite/tests/roles/should_fail/T9204a.hs +++ b/testsuite/tests/roles/should_fail/T9204a.hs @@ -1,2 +1,3 @@ +{-# LANGUAGE Haskell2010 #-} module T9204a where import {-# SOURCE #-} T9204 diff --git a/testsuite/tests/safeHaskell/check/Check01.hs b/testsuite/tests/safeHaskell/check/Check01.hs index 1d5df588a4f3..4d54accbf2c2 100644 --- a/testsuite/tests/safeHaskell/check/Check01.hs +++ b/testsuite/tests/safeHaskell/check/Check01.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# OPTIONS_GHC -fpackage-trust #-} {-# LANGUAGE Unsafe #-} module Check01 ( main' ) where diff --git a/testsuite/tests/safeHaskell/check/Check01.stderr b/testsuite/tests/safeHaskell/check/Check01.stderr index 5c8b8a3da5e2..b63d8d4a1005 100644 --- a/testsuite/tests/safeHaskell/check/Check01.stderr +++ b/testsuite/tests/safeHaskell/check/Check01.stderr @@ -1,4 +1,4 @@ [3 of 3] Compiling Check01 ( Check01.hs, Check01.o ) <no location info>: error: - The package (base-4.13.0.0) is required to be trusted but it isn't! + The package (base-4.16.0.0) is required to be trusted but it isn't! diff --git a/testsuite/tests/safeHaskell/check/Check01_A.hs b/testsuite/tests/safeHaskell/check/Check01_A.hs index 8b318a512442..44623da44d98 100644 --- a/testsuite/tests/safeHaskell/check/Check01_A.hs +++ b/testsuite/tests/safeHaskell/check/Check01_A.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Trustworthy #-} module Check01_A ( trace diff --git a/testsuite/tests/safeHaskell/check/Check01_B.hs b/testsuite/tests/safeHaskell/check/Check01_B.hs index b584e51b978e..7f2529e48156 100644 --- a/testsuite/tests/safeHaskell/check/Check01_B.hs +++ b/testsuite/tests/safeHaskell/check/Check01_B.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} -- Since Safe we require base package be trusted to compile diff --git a/testsuite/tests/safeHaskell/check/Check02.hs b/testsuite/tests/safeHaskell/check/Check02.hs index 50e64b79e8c5..83d971dc9ff6 100644 --- a/testsuite/tests/safeHaskell/check/Check02.hs +++ b/testsuite/tests/safeHaskell/check/Check02.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Unsafe #-} module Check02 ( main' ) where diff --git a/testsuite/tests/safeHaskell/check/Check02_A.hs b/testsuite/tests/safeHaskell/check/Check02_A.hs index d43dab727ad4..709161892e6b 100644 --- a/testsuite/tests/safeHaskell/check/Check02_A.hs +++ b/testsuite/tests/safeHaskell/check/Check02_A.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Trustworthy #-} module Check02_A ( trace diff --git a/testsuite/tests/safeHaskell/check/Check02_B.hs b/testsuite/tests/safeHaskell/check/Check02_B.hs index 10d45ccfbb99..70813b22ce70 100644 --- a/testsuite/tests/safeHaskell/check/Check02_B.hs +++ b/testsuite/tests/safeHaskell/check/Check02_B.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} -- Since Safe we require base package be trusted to compile diff --git a/testsuite/tests/safeHaskell/check/Check03.hs b/testsuite/tests/safeHaskell/check/Check03.hs index 71d158d7f65b..5e9d2b4cb495 100644 --- a/testsuite/tests/safeHaskell/check/Check03.hs +++ b/testsuite/tests/safeHaskell/check/Check03.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Unsafe #-} module Check03 where diff --git a/testsuite/tests/safeHaskell/check/Check03_A.hs b/testsuite/tests/safeHaskell/check/Check03_A.hs index e7b8d75d0335..7dfec4fdabac 100644 --- a/testsuite/tests/safeHaskell/check/Check03_A.hs +++ b/testsuite/tests/safeHaskell/check/Check03_A.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Trustworthy #-} module Check03_A ( trace diff --git a/testsuite/tests/safeHaskell/check/Check03_B.hs b/testsuite/tests/safeHaskell/check/Check03_B.hs index bce45af4e52b..dc274e06387a 100644 --- a/testsuite/tests/safeHaskell/check/Check03_B.hs +++ b/testsuite/tests/safeHaskell/check/Check03_B.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} -- Since Safe we require base package be trusted to compile diff --git a/testsuite/tests/safeHaskell/check/Check04.hs b/testsuite/tests/safeHaskell/check/Check04.hs index 2f6e94b3d59f..de277d651fb0 100644 --- a/testsuite/tests/safeHaskell/check/Check04.hs +++ b/testsuite/tests/safeHaskell/check/Check04.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Unsafe #-} module Main ( main ) where diff --git a/testsuite/tests/safeHaskell/check/Check04_A.hs b/testsuite/tests/safeHaskell/check/Check04_A.hs index 3f6b5f00e9ce..fc7b6165dd6d 100644 --- a/testsuite/tests/safeHaskell/check/Check04_A.hs +++ b/testsuite/tests/safeHaskell/check/Check04_A.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Trustworthy #-} module Check04_A ( trace diff --git a/testsuite/tests/safeHaskell/check/Check04_B.hs b/testsuite/tests/safeHaskell/check/Check04_B.hs index 5280c51fad51..20f9b4731b09 100644 --- a/testsuite/tests/safeHaskell/check/Check04_B.hs +++ b/testsuite/tests/safeHaskell/check/Check04_B.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} -- Since Safe we require base package be trusted to compile diff --git a/testsuite/tests/safeHaskell/check/Check06.hs b/testsuite/tests/safeHaskell/check/Check06.hs index 99649fa0791c..30c595530022 100644 --- a/testsuite/tests/safeHaskell/check/Check06.hs +++ b/testsuite/tests/safeHaskell/check/Check06.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Trustworthy, NoImplicitPrelude #-} {-# OPTIONS_GHC -fpackage-trust #-} diff --git a/testsuite/tests/safeHaskell/check/Check06_A.hs b/testsuite/tests/safeHaskell/check/Check06_A.hs index 4cda329feca1..f2c00ff3ab36 100644 --- a/testsuite/tests/safeHaskell/check/Check06_A.hs +++ b/testsuite/tests/safeHaskell/check/Check06_A.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} -- safe inferred, with requirement base is trusted module Check06_A where diff --git a/testsuite/tests/safeHaskell/check/Check08.hs b/testsuite/tests/safeHaskell/check/Check08.hs index dde6908f3084..da1aa6a50b51 100644 --- a/testsuite/tests/safeHaskell/check/Check08.hs +++ b/testsuite/tests/safeHaskell/check/Check08.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Trustworthy, NoImplicitPrelude #-} {-# OPTIONS_GHC -fpackage-trust #-} diff --git a/testsuite/tests/safeHaskell/check/Check08.stderr b/testsuite/tests/safeHaskell/check/Check08.stderr index d83ad784fd92..9eb6691bc8d7 100644 --- a/testsuite/tests/safeHaskell/check/Check08.stderr +++ b/testsuite/tests/safeHaskell/check/Check08.stderr @@ -3,4 +3,4 @@ [3 of 3] Compiling Check08 ( Check08.hs, Check08.o ) <no location info>: error: - The package (base-4.13.0.0) is required to be trusted but it isn't! + The package (base-4.16.0.0) is required to be trusted but it isn't! diff --git a/testsuite/tests/safeHaskell/check/Check08_A.hs b/testsuite/tests/safeHaskell/check/Check08_A.hs index 4438a34e0973..601bf518e469 100644 --- a/testsuite/tests/safeHaskell/check/Check08_A.hs +++ b/testsuite/tests/safeHaskell/check/Check08_A.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE NoImplicitPrelude #-} -- safe inferred, with no pkg trust reqs diff --git a/testsuite/tests/safeHaskell/check/Check08_B.hs b/testsuite/tests/safeHaskell/check/Check08_B.hs index 42d01f2b33bc..484f8dccec79 100644 --- a/testsuite/tests/safeHaskell/check/Check08_B.hs +++ b/testsuite/tests/safeHaskell/check/Check08_B.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} -- safe inferred, with requirement base is trusted module Check08_B where diff --git a/testsuite/tests/safeHaskell/check/Check09.hs b/testsuite/tests/safeHaskell/check/Check09.hs index cb04dada0f68..2770323517d1 100644 --- a/testsuite/tests/safeHaskell/check/Check09.hs +++ b/testsuite/tests/safeHaskell/check/Check09.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} module Check09 where diff --git a/testsuite/tests/safeHaskell/check/Check09.stderr b/testsuite/tests/safeHaskell/check/Check09.stderr index 6d1e0310754d..14af3c8f8b10 100644 --- a/testsuite/tests/safeHaskell/check/Check09.stderr +++ b/testsuite/tests/safeHaskell/check/Check09.stderr @@ -1,8 +1,8 @@ -Check09.hs:4:1: error: +Check09.hs:5:1: error: Prelude: Can't be safely imported! - The package (base-4.13.0.0) the module resides in isn't trusted. + The package (base-4.16.0.0) the module resides in isn't trusted. -Check09.hs:5:1: error: +Check09.hs:6:1: error: Data.ByteString.Char8: Can't be safely imported! - The package (bytestring-0.10.9.0) the module resides in isn't trusted. + The package (bytestring-0.10.12.0) the module resides in isn't trusted. diff --git a/testsuite/tests/safeHaskell/check/Check10.hs b/testsuite/tests/safeHaskell/check/Check10.hs index e72e5f388623..67c04b723673 100644 --- a/testsuite/tests/safeHaskell/check/Check10.hs +++ b/testsuite/tests/safeHaskell/check/Check10.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} module Check10 where diff --git a/testsuite/tests/safeHaskell/check/CheckB.hs b/testsuite/tests/safeHaskell/check/CheckB.hs index 7e649a159812..98faadc79e1f 100644 --- a/testsuite/tests/safeHaskell/check/CheckB.hs +++ b/testsuite/tests/safeHaskell/check/CheckB.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} -- Since Safe we require base package be trusted to compile diff --git a/testsuite/tests/safeHaskell/check/pkg01/ImpSafe01.hs b/testsuite/tests/safeHaskell/check/pkg01/ImpSafe01.hs index 107881b2d878..630c8bcef2a5 100644 --- a/testsuite/tests/safeHaskell/check/pkg01/ImpSafe01.hs +++ b/testsuite/tests/safeHaskell/check/pkg01/ImpSafe01.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} {-# LANGUAGE NoImplicitPrelude #-} module ImpSafe01 ( MyWord ) where diff --git a/testsuite/tests/safeHaskell/check/pkg01/ImpSafe01.stderr b/testsuite/tests/safeHaskell/check/pkg01/ImpSafe01.stderr index 5e4918e66f51..0381edfccb4d 100644 --- a/testsuite/tests/safeHaskell/check/pkg01/ImpSafe01.stderr +++ b/testsuite/tests/safeHaskell/check/pkg01/ImpSafe01.stderr @@ -1,4 +1,4 @@ -ImpSafe01.hs:9:1: error: +ImpSafe01.hs:10:1: error: Data.Word: Can't be safely imported! - The package (base-4.13.0.0) the module resides in isn't trusted. + The package (base-4.16.0.0) the module resides in isn't trusted. diff --git a/testsuite/tests/safeHaskell/check/pkg01/ImpSafe02.hs b/testsuite/tests/safeHaskell/check/pkg01/ImpSafe02.hs index c6ba0968d099..c27c62fa1c59 100644 --- a/testsuite/tests/safeHaskell/check/pkg01/ImpSafe02.hs +++ b/testsuite/tests/safeHaskell/check/pkg01/ImpSafe02.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} {-# LANGUAGE NoImplicitPrelude #-} module ImpSafe02 ( MyWord ) where diff --git a/testsuite/tests/safeHaskell/check/pkg01/ImpSafe03.hs b/testsuite/tests/safeHaskell/check/pkg01/ImpSafe03.hs index 485e9e238c14..989fa1ed2e3e 100644 --- a/testsuite/tests/safeHaskell/check/pkg01/ImpSafe03.hs +++ b/testsuite/tests/safeHaskell/check/pkg01/ImpSafe03.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Trustworthy #-} module Main where diff --git a/testsuite/tests/safeHaskell/check/pkg01/ImpSafe03_A.hs b/testsuite/tests/safeHaskell/check/pkg01/ImpSafe03_A.hs index 06f5d39754f1..63f121f7ea4f 100644 --- a/testsuite/tests/safeHaskell/check/pkg01/ImpSafe03_A.hs +++ b/testsuite/tests/safeHaskell/check/pkg01/ImpSafe03_A.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Trustworthy #-} module ImpSafe03_A where diff --git a/testsuite/tests/safeHaskell/check/pkg01/ImpSafe04.hs b/testsuite/tests/safeHaskell/check/pkg01/ImpSafe04.hs index 3a8882905f00..831d1b2bc1d9 100644 --- a/testsuite/tests/safeHaskell/check/pkg01/ImpSafe04.hs +++ b/testsuite/tests/safeHaskell/check/pkg01/ImpSafe04.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Trustworthy #-} {-# LANGUAGE NoImplicitPrelude #-} module ImpSafe04 ( MyWord ) where diff --git a/testsuite/tests/safeHaskell/check/pkg01/ImpSafe04.stderr b/testsuite/tests/safeHaskell/check/pkg01/ImpSafe04.stderr index cf9f32de452f..a0445afd23f8 100644 --- a/testsuite/tests/safeHaskell/check/pkg01/ImpSafe04.stderr +++ b/testsuite/tests/safeHaskell/check/pkg01/ImpSafe04.stderr @@ -1,4 +1,4 @@ -ImpSafe04.hs:9:1: error: +ImpSafe04.hs:10:1: error: Data.Word: Can't be safely imported! - The package (base-4.13.0.0) the module resides in isn't trusted. + The package (base-4.16.0.0) the module resides in isn't trusted. diff --git a/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly01.hs b/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly01.hs index 2143d3139b26..4a7364db8ed6 100644 --- a/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly01.hs +++ b/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly01.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} module Main where diff --git a/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly02.hs b/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly02.hs index 27281b9cce15..460ee1771e6d 100644 --- a/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly02.hs +++ b/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly02.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} module Main where diff --git a/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly03.hs b/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly03.hs index d09e39937d06..ea200510feb7 100644 --- a/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly03.hs +++ b/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly03.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} module Main where diff --git a/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly03.stderr b/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly03.stderr index 1afb523f9ae4..aef125b2ef54 100644 --- a/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly03.stderr +++ b/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly03.stderr @@ -1,4 +1,4 @@ -ImpSafeOnly03.hs:4:1: +ImpSafeOnly03.hs:5:1: error: M_SafePkg3: Can't be safely imported! The package (safePkg01-1.0) the module resides in isn't trusted. diff --git a/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly04.hs b/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly04.hs index d09e39937d06..ea200510feb7 100644 --- a/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly04.hs +++ b/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly04.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} module Main where diff --git a/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly05.hs b/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly05.hs index be577d1cccd0..e7c8403d974b 100644 --- a/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly05.hs +++ b/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly05.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} module Main where diff --git a/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly05.stderr b/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly05.stderr index 28826c8b16d8..7e854073bf65 100644 --- a/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly05.stderr +++ b/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly05.stderr @@ -1,4 +1,4 @@ -ImpSafeOnly05.hs:4:1: +ImpSafeOnly05.hs:5:1: error: M_SafePkg5: Can't be safely imported! The package (safePkg01-1.0) the module resides in isn't trusted. diff --git a/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly06.hs b/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly06.hs index be577d1cccd0..e7c8403d974b 100644 --- a/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly06.hs +++ b/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly06.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} module Main where diff --git a/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly07.hs b/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly07.hs index 975cff482a45..5b4b5a419931 100644 --- a/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly07.hs +++ b/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly07.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Trustworthy #-} module Main where diff --git a/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly08.hs b/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly08.hs index b81abf9ccbe4..d7bbdebb5634 100644 --- a/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly08.hs +++ b/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly08.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Trustworthy #-} module Main where diff --git a/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly09.hs b/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly09.hs index 9311f26a89c8..dd89994e80f5 100644 --- a/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly09.hs +++ b/testsuite/tests/safeHaskell/check/pkg01/ImpSafeOnly09.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Trustworthy #-} module Main where diff --git a/testsuite/tests/safeHaskell/flags/Flags02.hs b/testsuite/tests/safeHaskell/flags/Flags02.hs index 072d4509a104..080791133baf 100644 --- a/testsuite/tests/safeHaskell/flags/Flags02.hs +++ b/testsuite/tests/safeHaskell/flags/Flags02.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# OPTIONS_GHC -pgmdll pgmdll, -I., -L., -Uggg, -Dggg, -with-rtsopts full #-} -- | These are all flags that should be allowed diff --git a/testsuite/tests/safeHaskell/flags/SafeFlags01.hs b/testsuite/tests/safeHaskell/flags/SafeFlags01.hs index f5790eba6476..37f3e1891718 100644 --- a/testsuite/tests/safeHaskell/flags/SafeFlags01.hs +++ b/testsuite/tests/safeHaskell/flags/SafeFlags01.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} -- | Basic test to see if Safe flags compiles diff --git a/testsuite/tests/safeHaskell/flags/SafeFlags11.hs b/testsuite/tests/safeHaskell/flags/SafeFlags11.hs index e90b105ddef6..aded57d931ee 100644 --- a/testsuite/tests/safeHaskell/flags/SafeFlags11.hs +++ b/testsuite/tests/safeHaskell/flags/SafeFlags11.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} {-# LANGUAGE Safe #-} diff --git a/testsuite/tests/safeHaskell/flags/SafeFlags17.hs b/testsuite/tests/safeHaskell/flags/SafeFlags17.hs index 9bbd7a05502a..f991c1744367 100644 --- a/testsuite/tests/safeHaskell/flags/SafeFlags17.hs +++ b/testsuite/tests/safeHaskell/flags/SafeFlags17.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} {-# OPTIONS_GHC -fpackage-trust #-} -- | Basic test to see if Safe flags compiles diff --git a/testsuite/tests/safeHaskell/flags/SafeFlags17.stderr b/testsuite/tests/safeHaskell/flags/SafeFlags17.stderr index 4f8eae80b909..4ce52ce07228 100644 --- a/testsuite/tests/safeHaskell/flags/SafeFlags17.stderr +++ b/testsuite/tests/safeHaskell/flags/SafeFlags17.stderr @@ -1,4 +1,4 @@ -SafeFlags17.hs:4:8: error: +SafeFlags17.hs:5:8: error: Prelude: Can't be safely imported! - The package (base-4.13.0.0) the module resides in isn't trusted. + The package (base-4.16.0.0) the module resides in isn't trusted. diff --git a/testsuite/tests/safeHaskell/flags/SafeFlags20.hs b/testsuite/tests/safeHaskell/flags/SafeFlags20.hs index 8d415c1a093a..01a7074ea0b8 100644 --- a/testsuite/tests/safeHaskell/flags/SafeFlags20.hs +++ b/testsuite/tests/safeHaskell/flags/SafeFlags20.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} {-# OPTIONS_GHC -fpackage-trust #-} -- | Basic test to see if Safe flags compiles diff --git a/testsuite/tests/safeHaskell/flags/SafeFlags21.hs b/testsuite/tests/safeHaskell/flags/SafeFlags21.hs index 5169a0358399..7efc24b6ed31 100644 --- a/testsuite/tests/safeHaskell/flags/SafeFlags21.hs +++ b/testsuite/tests/safeHaskell/flags/SafeFlags21.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# OPTIONS_GHC -fwarn-unsafe #-} -- | Basic test to see if Safe warning flags compile -- Warn if module is inferred unsafe diff --git a/testsuite/tests/safeHaskell/flags/SafeFlags22.hs b/testsuite/tests/safeHaskell/flags/SafeFlags22.hs index 3d5d8dc1af84..4411f3d1a28e 100644 --- a/testsuite/tests/safeHaskell/flags/SafeFlags22.hs +++ b/testsuite/tests/safeHaskell/flags/SafeFlags22.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# OPTIONS_GHC -fwarn-unsafe #-} -- | Basic test to see if Safe warning flags compile -- Warn if module is inferred unsafe diff --git a/testsuite/tests/safeHaskell/flags/SafeFlags22.stderr b/testsuite/tests/safeHaskell/flags/SafeFlags22.stderr index 42d10b32c887..9d93e5e3326a 100644 --- a/testsuite/tests/safeHaskell/flags/SafeFlags22.stderr +++ b/testsuite/tests/safeHaskell/flags/SafeFlags22.stderr @@ -1,7 +1,7 @@ -SafeFlags22.hs:1:16: warning: [-Wunsafe] +SafeFlags22.hs:2:16: warning: [-Wunsafe] ‘SafeFlags22’ has been inferred as unsafe! Reason: - SafeFlags22.hs:7:1: error: + SafeFlags22.hs:8:1: error: System.IO.Unsafe: Can't be safely imported! The module itself isn't safe. diff --git a/testsuite/tests/safeHaskell/flags/SafeFlags23.hs b/testsuite/tests/safeHaskell/flags/SafeFlags23.hs index b3180bc1e107..854ea0a8568d 100644 --- a/testsuite/tests/safeHaskell/flags/SafeFlags23.hs +++ b/testsuite/tests/safeHaskell/flags/SafeFlags23.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# OPTIONS_GHC -fwarn-unsafe -Werror #-} -- | Basic test to see if Safe warning flags compile -- Warn if module is inferred unsafe diff --git a/testsuite/tests/safeHaskell/flags/SafeFlags23.stderr b/testsuite/tests/safeHaskell/flags/SafeFlags23.stderr index ea03484823b2..6fef7a3e4c5d 100644 --- a/testsuite/tests/safeHaskell/flags/SafeFlags23.stderr +++ b/testsuite/tests/safeHaskell/flags/SafeFlags23.stderr @@ -1,7 +1,7 @@ -SafeFlags23.hs:1:16: error: [-Wunsafe, -Werror=unsafe] +SafeFlags23.hs:2:16: error: [-Wunsafe, -Werror=unsafe] ‘SafeFlags22’ has been inferred as unsafe! Reason: - SafeFlags23.hs:7:1: error: + SafeFlags23.hs:8:1: error: System.IO.Unsafe: Can't be safely imported! The module itself isn't safe. diff --git a/testsuite/tests/safeHaskell/flags/SafeFlags25.hs b/testsuite/tests/safeHaskell/flags/SafeFlags25.hs index 7d650d6a72e7..f8d7ff292a67 100644 --- a/testsuite/tests/safeHaskell/flags/SafeFlags25.hs +++ b/testsuite/tests/safeHaskell/flags/SafeFlags25.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# OPTIONS_GHC -fwarn-safe #-} -- | Basic test to see if Safe warning flags compile -- Warn if module is inferred safe diff --git a/testsuite/tests/safeHaskell/flags/SafeFlags25.stderr b/testsuite/tests/safeHaskell/flags/SafeFlags25.stderr index bf82025b4c32..e26a813e83a5 100644 --- a/testsuite/tests/safeHaskell/flags/SafeFlags25.stderr +++ b/testsuite/tests/safeHaskell/flags/SafeFlags25.stderr @@ -1,3 +1,3 @@ -SafeFlags25.hs:1:16: warning: [-Wsafe] +SafeFlags25.hs:2:16: warning: [-Wsafe] ‘SafeFlags25’ has been inferred as safe! diff --git a/testsuite/tests/safeHaskell/flags/SafeFlags26.hs b/testsuite/tests/safeHaskell/flags/SafeFlags26.hs index 45b65f3d9e95..faf116c01fe5 100644 --- a/testsuite/tests/safeHaskell/flags/SafeFlags26.hs +++ b/testsuite/tests/safeHaskell/flags/SafeFlags26.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# OPTIONS_GHC -fwarn-safe -Werror #-} -- | Basic test to see if Safe warning flags compile -- Warn if module is inferred safe diff --git a/testsuite/tests/safeHaskell/flags/SafeFlags26.stderr b/testsuite/tests/safeHaskell/flags/SafeFlags26.stderr index 45047aa019e0..dabbd92c00e6 100644 --- a/testsuite/tests/safeHaskell/flags/SafeFlags26.stderr +++ b/testsuite/tests/safeHaskell/flags/SafeFlags26.stderr @@ -1,3 +1,3 @@ -SafeFlags26.hs:1:16: error: [-Wsafe, -Werror=safe] +SafeFlags26.hs:2:16: error: [-Wsafe, -Werror=safe] ‘SafeFlags26’ has been inferred as safe! diff --git a/testsuite/tests/safeHaskell/flags/all.T b/testsuite/tests/safeHaskell/flags/all.T index b92067d372fd..ed7ca4f88dea 100644 --- a/testsuite/tests/safeHaskell/flags/all.T +++ b/testsuite/tests/safeHaskell/flags/all.T @@ -59,8 +59,8 @@ test('SafeFlags28', normal, compile_fail, ['']) test('SafeFlags29', normal, compile_fail, ['']) # test certain flags are still allowed under -XSafe -test('Flags01', normal, compile, ['-XSafe']) -test('Flags02', normal, compile, ['-XSafe']) +test('Flags01', normal, compile, ['-XHaskell2010 -XSafe']) +test('Flags02', normal, compile, ['-XHaskell2010 -XSafe']) test('SafeFlags30', normal, compile_fail, ['']) diff --git a/testsuite/tests/safeHaskell/ghci/all.T b/testsuite/tests/safeHaskell/ghci/all.T index 26f72d20b8a6..fac80f36c08b 100644 --- a/testsuite/tests/safeHaskell/ghci/all.T +++ b/testsuite/tests/safeHaskell/ghci/all.T @@ -18,6 +18,6 @@ test('p16', normal, ghci_script, ['p16.script']) test('p17', normalise_version("bytestring"), ghci_script, ['p17.script']) # 7172 test('p18', normalise_version("bytestring"), ghci_script, ['p18.script']) -test('T12509', [extra_hc_opts('-XSafe')], ghci_script, ['T12509.script']) +test('T12509', [extra_hc_opts('-XNoGeneralizedNewtypeDeriving -XSafe')], ghci_script, ['T12509.script']) test('T19243', normal, ghci_script, ['T19243.script']) diff --git a/testsuite/tests/safeHaskell/ghci/p1.script b/testsuite/tests/safeHaskell/ghci/p1.script index 3c55ad720889..caa5eb838361 100644 --- a/testsuite/tests/safeHaskell/ghci/p1.script +++ b/testsuite/tests/safeHaskell/ghci/p1.script @@ -1,4 +1,5 @@ -- Test disabled language extensions +:set -XHaskell2010 :unset +s :set -XSafe diff --git a/testsuite/tests/safeHaskell/ghci/p10.script b/testsuite/tests/safeHaskell/ghci/p10.script index e1cefae4968a..4baa1aa63182 100644 --- a/testsuite/tests/safeHaskell/ghci/p10.script +++ b/testsuite/tests/safeHaskell/ghci/p10.script @@ -1,3 +1,4 @@ +:set -XHaskell2010 -- Test load works :unset +s :set -XSafe diff --git a/testsuite/tests/safeHaskell/ghci/p10.stderr b/testsuite/tests/safeHaskell/ghci/p10.stderr index fdb45da711a7..d3c7fe2f5eeb 100644 --- a/testsuite/tests/safeHaskell/ghci/p10.stderr +++ b/testsuite/tests/safeHaskell/ghci/p10.stderr @@ -1,2 +1,2 @@ -<interactive>:9:1: error: Variable not in scope: b +<interactive>:10:1: error: Variable not in scope: b diff --git a/testsuite/tests/safeHaskell/ghci/p11.script b/testsuite/tests/safeHaskell/ghci/p11.script index 19fb759600e1..f4aaaf833613 100644 --- a/testsuite/tests/safeHaskell/ghci/p11.script +++ b/testsuite/tests/safeHaskell/ghci/p11.script @@ -1,3 +1,4 @@ +:set -XHaskell2010 -- Test load works :unset +s :set -XSafe diff --git a/testsuite/tests/safeHaskell/ghci/p12.script b/testsuite/tests/safeHaskell/ghci/p12.script index 486302e8ed0d..df003ecbda41 100644 --- a/testsuite/tests/safeHaskell/ghci/p12.script +++ b/testsuite/tests/safeHaskell/ghci/p12.script @@ -1,3 +1,4 @@ +:set -XHaskell2010 -- Test you can't unset options :unset +s :set -XSafe diff --git a/testsuite/tests/safeHaskell/ghci/p13.script b/testsuite/tests/safeHaskell/ghci/p13.script index 950f95ab676d..0336061b0c3d 100644 --- a/testsuite/tests/safeHaskell/ghci/p13.script +++ b/testsuite/tests/safeHaskell/ghci/p13.script @@ -1,3 +1,4 @@ +:set -XHaskell2010 -- Test restricted functionality: Overlapping :unset +s :set -XSafe diff --git a/testsuite/tests/safeHaskell/ghci/p13.stderr b/testsuite/tests/safeHaskell/ghci/p13.stderr index 7ba149a36b40..ba73130146db 100644 --- a/testsuite/tests/safeHaskell/ghci/p13.stderr +++ b/testsuite/tests/safeHaskell/ghci/p13.stderr @@ -1,13 +1,13 @@ -<interactive>:10:1: error: - Unsafe overlapping instances for Pos [Int] - arising from a use of ‘res’ - The matching instance is: - instance [overlapping] [safe] Pos [Int] - -- Defined at <interactive>:8:30 - It is compiled in a Safe module and as such can only - overlap instances from the same module, however it - overlaps the following instances from different modules: - instance [safe] Pos [a] -- Defined at P13_A.hs:6:10 - In the expression: res [1 :: Int, 2 :: Int] - In an equation for ‘it’: it = res [1 :: Int, 2 :: Int] +<interactive>:11:1: error: + • Unsafe overlapping instances for Pos [Int] + arising from a use of ‘res’ + The matching instance is: + instance [overlapping] [safe] Pos [Int] + -- Defined at <interactive>:9:30 + It is compiled in a Safe module and as such can only + overlap instances from the same module, however it + overlaps the following instances from different modules: + instance [safe] Pos [a] -- Defined at P13_A.hs:6:10 + • In the expression: res [1 :: Int, 2 :: Int] + In an equation for ‘it’: it = res [1 :: Int, 2 :: Int] diff --git a/testsuite/tests/safeHaskell/ghci/p14.script b/testsuite/tests/safeHaskell/ghci/p14.script index 4802faf9404e..909b512c39df 100644 --- a/testsuite/tests/safeHaskell/ghci/p14.script +++ b/testsuite/tests/safeHaskell/ghci/p14.script @@ -1,3 +1,4 @@ +:set -XHaskell2010 -- Test restricted functionality: RULES :unset +s :set -XSafe diff --git a/testsuite/tests/safeHaskell/ghci/p14.stderr b/testsuite/tests/safeHaskell/ghci/p14.stderr index 736e8b448c80..3e0ac0ae46e7 100644 --- a/testsuite/tests/safeHaskell/ghci/p14.stderr +++ b/testsuite/tests/safeHaskell/ghci/p14.stderr @@ -1,5 +1,5 @@ -<interactive>:9:25: error: +<interactive>:10:25: error: • No instance for (Num a) arising from a use of ‘f’ Possible fix: add (Num a) to the context of the RULE "id/Int" • In the expression: f diff --git a/testsuite/tests/safeHaskell/ghci/p16.script b/testsuite/tests/safeHaskell/ghci/p16.script index 2bcea65c95c1..a4b829c9d80b 100644 --- a/testsuite/tests/safeHaskell/ghci/p16.script +++ b/testsuite/tests/safeHaskell/ghci/p16.script @@ -1,3 +1,4 @@ +:set -XHaskell2010 -- Test restricted functionality: GeneralizedNewtypeDeriving :unset +s :set -XSafe diff --git a/testsuite/tests/safeHaskell/ghci/p16.stderr b/testsuite/tests/safeHaskell/ghci/p16.stderr index 52315cce1791..36ee15327d5a 100644 --- a/testsuite/tests/safeHaskell/ghci/p16.stderr +++ b/testsuite/tests/safeHaskell/ghci/p16.stderr @@ -2,14 +2,14 @@ <no location info>: warning: -XGeneralizedNewtypeDeriving is not allowed in Safe Haskell; ignoring -XGeneralizedNewtypeDeriving -<interactive>:15:29: error: +<interactive>:16:29: error: • Can't make a derived instance of ‘Op T2’: ‘Op’ is not a stock derivable class (Eq, Show, etc.) Try GeneralizedNewtypeDeriving for GHC's newtype-deriving extension • In the newtype declaration for ‘T2’ -<interactive>:18:9: error: +<interactive>:19:9: error: • Data constructor not in scope: T2 :: T -> t - • Perhaps you meant ‘T1’ (line 12) + • Perhaps you meant ‘T1’ (line 13) -<interactive>:21:4: error: Variable not in scope: y +<interactive>:22:4: error: Variable not in scope: y diff --git a/testsuite/tests/safeHaskell/ghci/p17.script b/testsuite/tests/safeHaskell/ghci/p17.script index c9821d4e1793..1402ff1d2113 100644 --- a/testsuite/tests/safeHaskell/ghci/p17.script +++ b/testsuite/tests/safeHaskell/ghci/p17.script @@ -1,3 +1,4 @@ +:set -XHaskell2010 -- Test bad imports :unset +s :set -XSafe diff --git a/testsuite/tests/safeHaskell/ghci/p2.script b/testsuite/tests/safeHaskell/ghci/p2.script index 188915579e0c..7eab1d425fa0 100644 --- a/testsuite/tests/safeHaskell/ghci/p2.script +++ b/testsuite/tests/safeHaskell/ghci/p2.script @@ -1,3 +1,4 @@ +:set -XHaskell2010 -- Test bad options :unset +s diff --git a/testsuite/tests/safeHaskell/ghci/p3.script b/testsuite/tests/safeHaskell/ghci/p3.script index c2d9061739d2..9d34af8c4d66 100644 --- a/testsuite/tests/safeHaskell/ghci/p3.script +++ b/testsuite/tests/safeHaskell/ghci/p3.script @@ -1,3 +1,5 @@ +:set -XHaskell2010 + -- Test bad imports :unset +s :set -XSafe diff --git a/testsuite/tests/safeHaskell/ghci/p4.script b/testsuite/tests/safeHaskell/ghci/p4.script index 8d78f4067951..ae08ed619c3f 100644 --- a/testsuite/tests/safeHaskell/ghci/p4.script +++ b/testsuite/tests/safeHaskell/ghci/p4.script @@ -1,3 +1,4 @@ +:set -XHaskell2010 -- Test bad direct calls :unset +s :set -XSafe diff --git a/testsuite/tests/safeHaskell/ghci/p4.stderr b/testsuite/tests/safeHaskell/ghci/p4.stderr index 1d416eba395e..621960f9e25d 100644 --- a/testsuite/tests/safeHaskell/ghci/p4.stderr +++ b/testsuite/tests/safeHaskell/ghci/p4.stderr @@ -1,9 +1,8 @@ -<interactive>:5:9: error: +<interactive>:6:9: error: Not in scope: ‘System.IO.Unsafe.unsafePerformIO’ No module named ‘System.IO.Unsafe’ is imported. -<interactive>:6:9: error: - Variable not in scope: x :: IO b0 -> t +<interactive>:7:9: error: Variable not in scope: x :: IO b0 -> t -<interactive>:7:1: error: Variable not in scope: y +<interactive>:8:1: error: Variable not in scope: y diff --git a/testsuite/tests/safeHaskell/ghci/p5.script b/testsuite/tests/safeHaskell/ghci/p5.script index cdf6088812d8..b42973e0feaf 100644 --- a/testsuite/tests/safeHaskell/ghci/p5.script +++ b/testsuite/tests/safeHaskell/ghci/p5.script @@ -1,3 +1,4 @@ +:set -XHaskell2010 -- Test unsetting safe :unset +s :set -XSafe diff --git a/testsuite/tests/safeHaskell/ghci/p6.script b/testsuite/tests/safeHaskell/ghci/p6.script index 8590fd644968..2e326acd74ef 100644 --- a/testsuite/tests/safeHaskell/ghci/p6.script +++ b/testsuite/tests/safeHaskell/ghci/p6.script @@ -1,3 +1,4 @@ +:set -XHaskell2010 -- Test restricted functionality: FFI :unset +s :set -XSafe diff --git a/testsuite/tests/safeHaskell/ghci/p6.stderr b/testsuite/tests/safeHaskell/ghci/p6.stderr index 6213243bb0f7..d8dc09a996e5 100644 --- a/testsuite/tests/safeHaskell/ghci/p6.stderr +++ b/testsuite/tests/safeHaskell/ghci/p6.stderr @@ -1,10 +1,10 @@ -<interactive>:11:1: error: +<interactive>:12:1: error: • Unacceptable result type in foreign declaration: Safe Haskell is on, all FFI imports must be in the IO monad • When checking declaration: foreign import ccall safe "sin" c_sin :: Double -> Double -<interactive>:12:1: error: +<interactive>:13:1: error: • Variable not in scope: c_sin :: t0 -> t - • Perhaps you meant ‘c_sin'’ (line 7) + • Perhaps you meant ‘c_sin'’ (line 8) diff --git a/testsuite/tests/safeHaskell/ghci/p7.script b/testsuite/tests/safeHaskell/ghci/p7.script index ea4190b0a4d5..9aba5c55e77d 100644 --- a/testsuite/tests/safeHaskell/ghci/p7.script +++ b/testsuite/tests/safeHaskell/ghci/p7.script @@ -1,3 +1,5 @@ +:set -XHaskell2010 + -- Test load works :unset +s :set -XSafe diff --git a/testsuite/tests/safeHaskell/ghci/p8.script b/testsuite/tests/safeHaskell/ghci/p8.script index 7d5101f226eb..49e905bd45ec 100644 --- a/testsuite/tests/safeHaskell/ghci/p8.script +++ b/testsuite/tests/safeHaskell/ghci/p8.script @@ -1,3 +1,4 @@ +:set -XHaskell2010 -- Test load works :unset +s :set -XSafe diff --git a/testsuite/tests/safeHaskell/ghci/p9.script b/testsuite/tests/safeHaskell/ghci/p9.script index 298944dcae2e..b8d5f0bf13b7 100644 --- a/testsuite/tests/safeHaskell/ghci/p9.script +++ b/testsuite/tests/safeHaskell/ghci/p9.script @@ -1,3 +1,4 @@ +:set -XHaskell2010 -- Test load works :unset +s :set -XSafe diff --git a/testsuite/tests/safeHaskell/ghci/p9.stderr b/testsuite/tests/safeHaskell/ghci/p9.stderr index fdb45da711a7..d3c7fe2f5eeb 100644 --- a/testsuite/tests/safeHaskell/ghci/p9.stderr +++ b/testsuite/tests/safeHaskell/ghci/p9.stderr @@ -1,2 +1,2 @@ -<interactive>:9:1: error: Variable not in scope: b +<interactive>:10:1: error: Variable not in scope: b diff --git a/testsuite/tests/safeHaskell/overlapping/SH_Overlap1.hs b/testsuite/tests/safeHaskell/overlapping/SH_Overlap1.hs index beaf3881f534..896ddbff397e 100644 --- a/testsuite/tests/safeHaskell/overlapping/SH_Overlap1.hs +++ b/testsuite/tests/safeHaskell/overlapping/SH_Overlap1.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Trustworthy #-} {-# LANGUAGE FlexibleInstances #-} diff --git a/testsuite/tests/safeHaskell/overlapping/SH_Overlap1.stderr b/testsuite/tests/safeHaskell/overlapping/SH_Overlap1.stderr index 20349c602493..54dab18cd3e3 100644 --- a/testsuite/tests/safeHaskell/overlapping/SH_Overlap1.stderr +++ b/testsuite/tests/safeHaskell/overlapping/SH_Overlap1.stderr @@ -2,14 +2,15 @@ [2 of 3] Compiling SH_Overlap1_A ( SH_Overlap1_A.hs, SH_Overlap1_A.o ) [3 of 3] Compiling SH_Overlap1 ( SH_Overlap1.hs, SH_Overlap1.o ) -SH_Overlap1.hs:15:8: error: - Unsafe overlapping instances for C [Int] arising from a use of ‘f’ - The matching instance is: - instance [overlap ok] [safe] C [Int] - -- Defined at SH_Overlap1_A.hs:11:3 - It is compiled in a Safe module and as such can only - overlap instances from the same module, however it - overlaps the following instances from different modules: - instance C [a] -- Defined at SH_Overlap1.hs:11:3 - In the expression: f ([1, 2, 3, 4] :: [Int]) - In an equation for ‘test’: test = f ([1, 2, 3, 4] :: [Int]) +SH_Overlap1.hs:16:8: error: + • Unsafe overlapping instances for C [Int] + arising from a use of ‘f’ + The matching instance is: + instance [overlap ok] [safe] C [Int] + -- Defined at SH_Overlap1_A.hs:12:3 + It is compiled in a Safe module and as such can only + overlap instances from the same module, however it + overlaps the following instances from different modules: + instance C [a] -- Defined at SH_Overlap1.hs:12:3 + • In the expression: f ([1, 2, 3, 4] :: [Int]) + In an equation for ‘test’: test = f ([1, 2, 3, 4] :: [Int]) diff --git a/testsuite/tests/safeHaskell/overlapping/SH_Overlap10.hs b/testsuite/tests/safeHaskell/overlapping/SH_Overlap10.hs index 7c5e5a1929fa..8f455d05018e 100644 --- a/testsuite/tests/safeHaskell/overlapping/SH_Overlap10.hs +++ b/testsuite/tests/safeHaskell/overlapping/SH_Overlap10.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# OPTIONS_GHC -fwarn-unsafe #-} {-# LANGUAGE FlexibleInstances #-} diff --git a/testsuite/tests/safeHaskell/overlapping/SH_Overlap10_A.hs b/testsuite/tests/safeHaskell/overlapping/SH_Overlap10_A.hs index 76d0b2ea9e8b..551088edbda2 100644 --- a/testsuite/tests/safeHaskell/overlapping/SH_Overlap10_A.hs +++ b/testsuite/tests/safeHaskell/overlapping/SH_Overlap10_A.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# OPTIONS_GHC -fwarn-unsafe #-} {-# LANGUAGE FlexibleInstances #-} module SH_Overlap10_A ( diff --git a/testsuite/tests/safeHaskell/overlapping/SH_Overlap10_B.hs b/testsuite/tests/safeHaskell/overlapping/SH_Overlap10_B.hs index 1efb86c064cf..72a9dc5a1e03 100644 --- a/testsuite/tests/safeHaskell/overlapping/SH_Overlap10_B.hs +++ b/testsuite/tests/safeHaskell/overlapping/SH_Overlap10_B.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# OPTIONS_GHC -fwarn-unsafe #-} module SH_Overlap10_B ( C(..) diff --git a/testsuite/tests/safeHaskell/overlapping/SH_Overlap11.hs b/testsuite/tests/safeHaskell/overlapping/SH_Overlap11.hs index f591c0a18876..2c336ed037a7 100644 --- a/testsuite/tests/safeHaskell/overlapping/SH_Overlap11.hs +++ b/testsuite/tests/safeHaskell/overlapping/SH_Overlap11.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# OPTIONS_GHC -fwarn-unsafe #-} {-# LANGUAGE FlexibleInstances #-} diff --git a/testsuite/tests/safeHaskell/overlapping/SH_Overlap11.stderr b/testsuite/tests/safeHaskell/overlapping/SH_Overlap11.stderr index aca02ef4a9fa..9eb029951f66 100644 --- a/testsuite/tests/safeHaskell/overlapping/SH_Overlap11.stderr +++ b/testsuite/tests/safeHaskell/overlapping/SH_Overlap11.stderr @@ -2,18 +2,18 @@ [2 of 3] Compiling SH_Overlap11_A ( SH_Overlap11_A.hs, SH_Overlap11_A.o ) [3 of 3] Compiling SH_Overlap11 ( SH_Overlap11.hs, SH_Overlap11.o ) -SH_Overlap11.hs:1:16: warning: [-Wunsafe] +SH_Overlap11.hs:2:16: warning: [-Wunsafe] ‘SH_Overlap11’ has been inferred as unsafe! Reason: - SH_Overlap11.hs:17:8: warning: + SH_Overlap11.hs:18:8: warning: • Unsafe overlapping instances for C [Int] arising from a use of ‘f’ The matching instance is: instance [overlap ok] [safe] C [Int] - -- Defined at SH_Overlap11_A.hs:11:3 + -- Defined at SH_Overlap11_A.hs:12:3 It is compiled in a Safe module and as such can only overlap instances from the same module, however it overlaps the following instances from different modules: - instance C [a] -- Defined at SH_Overlap11.hs:13:3 + instance C [a] -- Defined at SH_Overlap11.hs:14:3 • In the expression: f ([1, 2, 3, 4] :: [Int]) In an equation for ‘test’: test = f ([1, 2, 3, 4] :: [Int]) diff --git a/testsuite/tests/safeHaskell/overlapping/SH_Overlap11_A.hs b/testsuite/tests/safeHaskell/overlapping/SH_Overlap11_A.hs index 100a9f30db29..6f834cae2481 100644 --- a/testsuite/tests/safeHaskell/overlapping/SH_Overlap11_A.hs +++ b/testsuite/tests/safeHaskell/overlapping/SH_Overlap11_A.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# OPTIONS_GHC -fwarn-unsafe #-} {-# LANGUAGE FlexibleInstances #-} module SH_Overlap11_A ( diff --git a/testsuite/tests/safeHaskell/overlapping/SH_Overlap11_B.hs b/testsuite/tests/safeHaskell/overlapping/SH_Overlap11_B.hs index 63ba1d7c6ff0..4d1e226a96bb 100644 --- a/testsuite/tests/safeHaskell/overlapping/SH_Overlap11_B.hs +++ b/testsuite/tests/safeHaskell/overlapping/SH_Overlap11_B.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# OPTIONS_GHC -fwarn-unsafe #-} module SH_Overlap11_B ( C(..) diff --git a/testsuite/tests/safeHaskell/overlapping/SH_Overlap1_A.hs b/testsuite/tests/safeHaskell/overlapping/SH_Overlap1_A.hs index d231bc93651a..6a8a2c2970e1 100644 --- a/testsuite/tests/safeHaskell/overlapping/SH_Overlap1_A.hs +++ b/testsuite/tests/safeHaskell/overlapping/SH_Overlap1_A.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} {-# LANGUAGE FlexibleInstances #-} module SH_Overlap1_A ( diff --git a/testsuite/tests/safeHaskell/overlapping/SH_Overlap1_B.hs b/testsuite/tests/safeHaskell/overlapping/SH_Overlap1_B.hs index 1dbb59b6b463..fb2e648854a0 100644 --- a/testsuite/tests/safeHaskell/overlapping/SH_Overlap1_B.hs +++ b/testsuite/tests/safeHaskell/overlapping/SH_Overlap1_B.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} module SH_Overlap1_B ( C(..) diff --git a/testsuite/tests/safeHaskell/overlapping/SH_Overlap2.hs b/testsuite/tests/safeHaskell/overlapping/SH_Overlap2.hs index 5df87abcab09..9ce118d9cbb9 100644 --- a/testsuite/tests/safeHaskell/overlapping/SH_Overlap2.hs +++ b/testsuite/tests/safeHaskell/overlapping/SH_Overlap2.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Trustworthy #-} {-# LANGUAGE FlexibleInstances #-} diff --git a/testsuite/tests/safeHaskell/overlapping/SH_Overlap2.stderr b/testsuite/tests/safeHaskell/overlapping/SH_Overlap2.stderr index b4f15515b04c..2eed7608d148 100644 --- a/testsuite/tests/safeHaskell/overlapping/SH_Overlap2.stderr +++ b/testsuite/tests/safeHaskell/overlapping/SH_Overlap2.stderr @@ -2,14 +2,15 @@ [2 of 3] Compiling SH_Overlap2_A ( SH_Overlap2_A.hs, SH_Overlap2_A.o ) [3 of 3] Compiling SH_Overlap2 ( SH_Overlap2.hs, SH_Overlap2.o ) -SH_Overlap2.hs:18:8: error: - Unsafe overlapping instances for C [Int] arising from a use of ‘f’ - The matching instance is: - instance [overlap ok] [safe] C [Int] - -- Defined at SH_Overlap2_A.hs:11:3 - It is compiled in a Safe module and as such can only - overlap instances from the same module, however it - overlaps the following instances from different modules: - instance C [a] -- Defined at SH_Overlap2.hs:14:3 - In the expression: f ([1, 2, 3, 4] :: [Int]) - In an equation for ‘test’: test = f ([1, 2, 3, 4] :: [Int]) +SH_Overlap2.hs:19:8: error: + • Unsafe overlapping instances for C [Int] + arising from a use of ‘f’ + The matching instance is: + instance [overlap ok] [safe] C [Int] + -- Defined at SH_Overlap2_A.hs:12:3 + It is compiled in a Safe module and as such can only + overlap instances from the same module, however it + overlaps the following instances from different modules: + instance C [a] -- Defined at SH_Overlap2.hs:15:3 + • In the expression: f ([1, 2, 3, 4] :: [Int]) + In an equation for ‘test’: test = f ([1, 2, 3, 4] :: [Int]) diff --git a/testsuite/tests/safeHaskell/overlapping/SH_Overlap2_A.hs b/testsuite/tests/safeHaskell/overlapping/SH_Overlap2_A.hs index 2510818e06ca..2e2be0bd562c 100644 --- a/testsuite/tests/safeHaskell/overlapping/SH_Overlap2_A.hs +++ b/testsuite/tests/safeHaskell/overlapping/SH_Overlap2_A.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} {-# LANGUAGE FlexibleInstances #-} module SH_Overlap2_A ( diff --git a/testsuite/tests/safeHaskell/overlapping/SH_Overlap2_B.hs b/testsuite/tests/safeHaskell/overlapping/SH_Overlap2_B.hs index fcd8ef8f56a7..0fbb784ff2ea 100644 --- a/testsuite/tests/safeHaskell/overlapping/SH_Overlap2_B.hs +++ b/testsuite/tests/safeHaskell/overlapping/SH_Overlap2_B.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} module SH_Overlap2_B ( C(..) diff --git a/testsuite/tests/safeHaskell/overlapping/SH_Overlap3.hs b/testsuite/tests/safeHaskell/overlapping/SH_Overlap3.hs index 8ffa53f84b91..019c315db36b 100644 --- a/testsuite/tests/safeHaskell/overlapping/SH_Overlap3.hs +++ b/testsuite/tests/safeHaskell/overlapping/SH_Overlap3.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Unsafe #-} {-# LANGUAGE FlexibleInstances #-} diff --git a/testsuite/tests/safeHaskell/overlapping/SH_Overlap3_A.hs b/testsuite/tests/safeHaskell/overlapping/SH_Overlap3_A.hs index 0a3393ef4da7..50eedd6e1a6c 100644 --- a/testsuite/tests/safeHaskell/overlapping/SH_Overlap3_A.hs +++ b/testsuite/tests/safeHaskell/overlapping/SH_Overlap3_A.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} {-# LANGUAGE FlexibleInstances #-} module SH_Overlap3_A ( diff --git a/testsuite/tests/safeHaskell/overlapping/SH_Overlap3_B.hs b/testsuite/tests/safeHaskell/overlapping/SH_Overlap3_B.hs index 4908d7342748..12d6d5103d0a 100644 --- a/testsuite/tests/safeHaskell/overlapping/SH_Overlap3_B.hs +++ b/testsuite/tests/safeHaskell/overlapping/SH_Overlap3_B.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} module SH_Overlap3_B ( C(..) diff --git a/testsuite/tests/safeHaskell/overlapping/SH_Overlap4.hs b/testsuite/tests/safeHaskell/overlapping/SH_Overlap4.hs index 0d9f445080bf..a9951fac948e 100644 --- a/testsuite/tests/safeHaskell/overlapping/SH_Overlap4.hs +++ b/testsuite/tests/safeHaskell/overlapping/SH_Overlap4.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Unsafe #-} {-# LANGUAGE FlexibleInstances #-} diff --git a/testsuite/tests/safeHaskell/overlapping/SH_Overlap4_A.hs b/testsuite/tests/safeHaskell/overlapping/SH_Overlap4_A.hs index bb1625e22262..a0caa60cfb34 100644 --- a/testsuite/tests/safeHaskell/overlapping/SH_Overlap4_A.hs +++ b/testsuite/tests/safeHaskell/overlapping/SH_Overlap4_A.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} {-# LANGUAGE FlexibleInstances #-} module SH_Overlap4_A ( diff --git a/testsuite/tests/safeHaskell/overlapping/SH_Overlap4_B.hs b/testsuite/tests/safeHaskell/overlapping/SH_Overlap4_B.hs index 2a53fff8c6d8..56f974fd064f 100644 --- a/testsuite/tests/safeHaskell/overlapping/SH_Overlap4_B.hs +++ b/testsuite/tests/safeHaskell/overlapping/SH_Overlap4_B.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} module SH_Overlap4_B ( C(..) diff --git a/testsuite/tests/safeHaskell/overlapping/SH_Overlap5.hs b/testsuite/tests/safeHaskell/overlapping/SH_Overlap5.hs index 185946d56fe5..79b556758042 100644 --- a/testsuite/tests/safeHaskell/overlapping/SH_Overlap5.hs +++ b/testsuite/tests/safeHaskell/overlapping/SH_Overlap5.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} {-# LANGUAGE FlexibleInstances #-} diff --git a/testsuite/tests/safeHaskell/overlapping/SH_Overlap5.stderr b/testsuite/tests/safeHaskell/overlapping/SH_Overlap5.stderr index 8c2bc7df9d44..9de7ecc708b3 100644 --- a/testsuite/tests/safeHaskell/overlapping/SH_Overlap5.stderr +++ b/testsuite/tests/safeHaskell/overlapping/SH_Overlap5.stderr @@ -2,14 +2,15 @@ [2 of 3] Compiling SH_Overlap5_A ( SH_Overlap5_A.hs, SH_Overlap5_A.o ) [3 of 3] Compiling SH_Overlap5 ( SH_Overlap5.hs, SH_Overlap5.o ) -SH_Overlap5.hs:15:8: error: - Unsafe overlapping instances for C [Int] arising from a use of ‘f’ - The matching instance is: - instance [overlap ok] [safe] C [Int] - -- Defined at SH_Overlap5_A.hs:11:3 - It is compiled in a Safe module and as such can only - overlap instances from the same module, however it - overlaps the following instances from different modules: - instance [safe] C [a] -- Defined at SH_Overlap5.hs:11:3 - In the expression: f ([1, 2, 3, 4] :: [Int]) - In an equation for ‘test’: test = f ([1, 2, 3, 4] :: [Int]) +SH_Overlap5.hs:16:8: error: + • Unsafe overlapping instances for C [Int] + arising from a use of ‘f’ + The matching instance is: + instance [overlap ok] [safe] C [Int] + -- Defined at SH_Overlap5_A.hs:12:3 + It is compiled in a Safe module and as such can only + overlap instances from the same module, however it + overlaps the following instances from different modules: + instance [safe] C [a] -- Defined at SH_Overlap5.hs:12:3 + • In the expression: f ([1, 2, 3, 4] :: [Int]) + In an equation for ‘test’: test = f ([1, 2, 3, 4] :: [Int]) diff --git a/testsuite/tests/safeHaskell/overlapping/SH_Overlap5_A.hs b/testsuite/tests/safeHaskell/overlapping/SH_Overlap5_A.hs index 71c6bac0f05e..7032b1674759 100644 --- a/testsuite/tests/safeHaskell/overlapping/SH_Overlap5_A.hs +++ b/testsuite/tests/safeHaskell/overlapping/SH_Overlap5_A.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} {-# LANGUAGE FlexibleInstances #-} module SH_Overlap5_A ( diff --git a/testsuite/tests/safeHaskell/overlapping/SH_Overlap5_B.hs b/testsuite/tests/safeHaskell/overlapping/SH_Overlap5_B.hs index e7e8102b983a..3dc6ff18fc86 100644 --- a/testsuite/tests/safeHaskell/overlapping/SH_Overlap5_B.hs +++ b/testsuite/tests/safeHaskell/overlapping/SH_Overlap5_B.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} module SH_Overlap5_B ( C(..) diff --git a/testsuite/tests/safeHaskell/overlapping/SH_Overlap6.hs b/testsuite/tests/safeHaskell/overlapping/SH_Overlap6.hs index e38037ab8b75..fa07f61e91a2 100644 --- a/testsuite/tests/safeHaskell/overlapping/SH_Overlap6.hs +++ b/testsuite/tests/safeHaskell/overlapping/SH_Overlap6.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} {-# LANGUAGE FlexibleInstances #-} diff --git a/testsuite/tests/safeHaskell/overlapping/SH_Overlap6.stderr b/testsuite/tests/safeHaskell/overlapping/SH_Overlap6.stderr index e5b7ac95d6d9..7804b9e5d581 100644 --- a/testsuite/tests/safeHaskell/overlapping/SH_Overlap6.stderr +++ b/testsuite/tests/safeHaskell/overlapping/SH_Overlap6.stderr @@ -2,14 +2,15 @@ [2 of 3] Compiling SH_Overlap6_A ( SH_Overlap6_A.hs, SH_Overlap6_A.o ) [3 of 3] Compiling SH_Overlap6 ( SH_Overlap6.hs, SH_Overlap6.o ) -SH_Overlap6.hs:14:8: error: - Unsafe overlapping instances for C [Int] arising from a use of ‘f’ - The matching instance is: - instance [overlap ok] [safe] C [Int] - -- Defined at SH_Overlap6_A.hs:11:3 - It is compiled in a Safe module and as such can only - overlap instances from the same module, however it - overlaps the following instances from different modules: - instance [safe] C [a] -- Defined at SH_Overlap6.hs:10:10 - In the expression: f ([1, 2, 3, 4] :: [Int]) - In an equation for ‘test’: test = f ([1, 2, 3, 4] :: [Int]) +SH_Overlap6.hs:15:8: error: + • Unsafe overlapping instances for C [Int] + arising from a use of ‘f’ + The matching instance is: + instance [overlap ok] [safe] C [Int] + -- Defined at SH_Overlap6_A.hs:12:3 + It is compiled in a Safe module and as such can only + overlap instances from the same module, however it + overlaps the following instances from different modules: + instance [safe] C [a] -- Defined at SH_Overlap6.hs:11:10 + • In the expression: f ([1, 2, 3, 4] :: [Int]) + In an equation for ‘test’: test = f ([1, 2, 3, 4] :: [Int]) diff --git a/testsuite/tests/safeHaskell/overlapping/SH_Overlap6_A.hs b/testsuite/tests/safeHaskell/overlapping/SH_Overlap6_A.hs index 788c2f384bfe..b495e284f023 100644 --- a/testsuite/tests/safeHaskell/overlapping/SH_Overlap6_A.hs +++ b/testsuite/tests/safeHaskell/overlapping/SH_Overlap6_A.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# OPTIONS_GHC -fwarn-unsafe #-} {-# LANGUAGE FlexibleInstances #-} module SH_Overlap6_A ( diff --git a/testsuite/tests/safeHaskell/overlapping/SH_Overlap6_B.hs b/testsuite/tests/safeHaskell/overlapping/SH_Overlap6_B.hs index 5ec45676e94c..0a8a81156ec6 100644 --- a/testsuite/tests/safeHaskell/overlapping/SH_Overlap6_B.hs +++ b/testsuite/tests/safeHaskell/overlapping/SH_Overlap6_B.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# OPTIONS_GHC -fwarn-unsafe #-} module SH_Overlap6_B ( C(..) diff --git a/testsuite/tests/safeHaskell/overlapping/SH_Overlap7.hs b/testsuite/tests/safeHaskell/overlapping/SH_Overlap7.hs index e99e73fd4168..179008744f51 100644 --- a/testsuite/tests/safeHaskell/overlapping/SH_Overlap7.hs +++ b/testsuite/tests/safeHaskell/overlapping/SH_Overlap7.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# OPTIONS_GHC -fwarn-unsafe #-} {-# LANGUAGE FlexibleInstances #-} diff --git a/testsuite/tests/safeHaskell/overlapping/SH_Overlap7.stderr b/testsuite/tests/safeHaskell/overlapping/SH_Overlap7.stderr index 45701f2529ca..ce90de4c72d3 100644 --- a/testsuite/tests/safeHaskell/overlapping/SH_Overlap7.stderr +++ b/testsuite/tests/safeHaskell/overlapping/SH_Overlap7.stderr @@ -2,18 +2,18 @@ [2 of 3] Compiling SH_Overlap7_A ( SH_Overlap7_A.hs, SH_Overlap7_A.o ) [3 of 3] Compiling SH_Overlap7 ( SH_Overlap7.hs, SH_Overlap7.o ) -SH_Overlap7.hs:1:16: error: [-Wunsafe, -Werror=unsafe] +SH_Overlap7.hs:2:16: error: [-Wunsafe, -Werror=unsafe] ‘SH_Overlap7’ has been inferred as unsafe! Reason: - SH_Overlap7.hs:14:8: warning: + SH_Overlap7.hs:15:8: warning: • Unsafe overlapping instances for C [Int] arising from a use of ‘f’ The matching instance is: instance [overlap ok] [safe] C [Int] - -- Defined at SH_Overlap7_A.hs:12:3 + -- Defined at SH_Overlap7_A.hs:13:3 It is compiled in a Safe module and as such can only overlap instances from the same module, however it overlaps the following instances from different modules: - instance C [a] -- Defined at SH_Overlap7.hs:10:10 + instance C [a] -- Defined at SH_Overlap7.hs:11:10 • In the expression: f ([1, 2, 3, 4] :: [Int]) In an equation for ‘test’: test = f ([1, 2, 3, 4] :: [Int]) diff --git a/testsuite/tests/safeHaskell/overlapping/SH_Overlap7_A.hs b/testsuite/tests/safeHaskell/overlapping/SH_Overlap7_A.hs index 972c5abf4e53..3ad4c876414b 100644 --- a/testsuite/tests/safeHaskell/overlapping/SH_Overlap7_A.hs +++ b/testsuite/tests/safeHaskell/overlapping/SH_Overlap7_A.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# OPTIONS_GHC -fwarn-unsafe #-} {-# LANGUAGE FlexibleInstances #-} {-# LANGUAGE Safe #-} diff --git a/testsuite/tests/safeHaskell/overlapping/SH_Overlap7_B.hs b/testsuite/tests/safeHaskell/overlapping/SH_Overlap7_B.hs index 382cad01c893..8e0121f9b7a5 100644 --- a/testsuite/tests/safeHaskell/overlapping/SH_Overlap7_B.hs +++ b/testsuite/tests/safeHaskell/overlapping/SH_Overlap7_B.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# OPTIONS_GHC -fwarn-unsafe #-} {-# LANGUAGE Safe #-} module SH_Overlap7_B ( diff --git a/testsuite/tests/safeHaskell/overlapping/SH_Overlap8.hs b/testsuite/tests/safeHaskell/overlapping/SH_Overlap8.hs index 6026769941fe..173c4ff03f88 100644 --- a/testsuite/tests/safeHaskell/overlapping/SH_Overlap8.hs +++ b/testsuite/tests/safeHaskell/overlapping/SH_Overlap8.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} {-# LANGUAGE FlexibleInstances #-} diff --git a/testsuite/tests/safeHaskell/overlapping/SH_Overlap8_A.hs b/testsuite/tests/safeHaskell/overlapping/SH_Overlap8_A.hs index 8c19b1acbdc3..3d437aaeadc5 100644 --- a/testsuite/tests/safeHaskell/overlapping/SH_Overlap8_A.hs +++ b/testsuite/tests/safeHaskell/overlapping/SH_Overlap8_A.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} {-# LANGUAGE FlexibleInstances #-} module SH_Overlap8_A ( diff --git a/testsuite/tests/safeHaskell/overlapping/SH_Overlap9.hs b/testsuite/tests/safeHaskell/overlapping/SH_Overlap9.hs index 5ae00fa101fa..cdce1d9fcb39 100644 --- a/testsuite/tests/safeHaskell/overlapping/SH_Overlap9.hs +++ b/testsuite/tests/safeHaskell/overlapping/SH_Overlap9.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# OPTIONS_GHC -fwarn-safe #-} {-# LANGUAGE FlexibleInstances #-} diff --git a/testsuite/tests/safeHaskell/overlapping/SH_Overlap9_A.hs b/testsuite/tests/safeHaskell/overlapping/SH_Overlap9_A.hs index 580bbda17bb7..608c937ce9bc 100644 --- a/testsuite/tests/safeHaskell/overlapping/SH_Overlap9_A.hs +++ b/testsuite/tests/safeHaskell/overlapping/SH_Overlap9_A.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# OPTIONS_GHC -fwarn-unsafe #-} {-# LANGUAGE FlexibleInstances #-} module SH_Overlap9_A ( diff --git a/testsuite/tests/safeHaskell/overlapping/SH_Overlap9_B.hs b/testsuite/tests/safeHaskell/overlapping/SH_Overlap9_B.hs index 4cbf88692cd1..9db3e5a99fb3 100644 --- a/testsuite/tests/safeHaskell/overlapping/SH_Overlap9_B.hs +++ b/testsuite/tests/safeHaskell/overlapping/SH_Overlap9_B.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# OPTIONS_GHC -fwarn-unsafe #-} module SH_Overlap9_B ( C(..) diff --git a/testsuite/tests/safeHaskell/safeInfered/Mixed02.hs b/testsuite/tests/safeHaskell/safeInfered/Mixed02.hs index 062c2db64d95..165feca79bf4 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 b170a4550d24..9fa48d43389c 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 fba39654d996..9212656d6c3c 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 4f4dcccbcf46..0a9523ca33cc 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 0e48580c980e..a1e953ced5f8 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 f66ac43d78f0..9f52c43f40e6 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 6656c5acf71a..c1e4c37c9916 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 57438d2761dc..bf9b8c9e7020 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 9c7af1223170..cea614c558e4 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 9844ec6525bb..d6947e2d2729 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 8752383a6bcc..deb2e8494f1d 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 6f4db5db7951..da7e808acb17 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 1e933ac3b038..ad4f232cc245 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 5d194064b8bf..7815bb7c8143 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 c9e5c964cbf5..72eeaeb097f2 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 507367929b2d..84ed104d4379 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 5e824de64131..7efaba349045 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 a1820aa4a19c..2621ec6cffe1 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 9dfaccd950d6..5a374cb99daf 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 7d42cb016fae..7723e98dc184 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 ad63e090e113..fe3e27ef5f2e 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 9938109dcbb8..ff4a4e3631a5 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 b1db9ea5786c..0a356f190bbb 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 4e705d6a1694..26981723483f 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 67105965d848..f41e7e32f3c5 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 e5593d57e9e4..203e241c99f9 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 67220ac4d011..115070b57321 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 8a48fec4b024..b722af9bc90b 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 712d02a3509a..4bf2b2bddcbe 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 e70f03df382d..4a0eb8000d18 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 a5bb12720240..f12f5f90df7b 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 42c8c3d1e59a..623f4aea3cd6 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 394d7e6999ad..b9e2eff6cadd 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 d88eda96b1c1..d8c5137c8260 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 1c1e61d3c549..4dcd5c82eac1 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 bf9b623eaa23..b5ddab3f35bc 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 3ba1584b088f..ddedb0940723 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 f626cf952f9a..fb4488000b40 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 34555594e925..c8fd8b3f7b2f 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 18a6a459c739..919eec4e6b4c 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 d209dcf5febd..aefaacac30dc 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 a39b46e2a073..24ae448a88dc 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 f05bf7fa8c89..e3529474bd9b 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 defc3a52439e..ae9281643eb0 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 5b9f64210fb0..644c63f4cfa1 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 427c97b0acca..72008319c547 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 b3e7f34586da..ffc65d093b1c 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 7f17a136ff6a..ff2abe647d6b 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 a6dbfe17452c..1aaaf8e47a7a 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 58db37d3f0fe..2e15aa3954b8 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 587bc4edbfd6..4b0b33b410e9 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 afe188db4f9b..f3eeea02adb8 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 6d2afb21935d..5424c5f2a211 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 6f62ca5c94ee..0d1924bf8f9a 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 2ee83ac1407b..881db587d513 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 ded02de88888..433824f8bd88 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 6ddea45af169..ba23b72ee11b 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 d8e8b84fa592..1d02985734d7 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 c91f4213445f..90e6d5b6f19b 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 76258d362b42..3c9b3109f783 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 dfd4193b7a62..297750445752 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 671a64822b50..8680fe5d6f5f 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 323bb19a39a1..98b136020228 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 43982939b8bf..7efc9157e721 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 11116b6460ad..91a4ec3547ed 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 diff --git a/testsuite/tests/safeHaskell/safeLanguage/SafeLang01.hs b/testsuite/tests/safeHaskell/safeLanguage/SafeLang01.hs index 5920c03161c8..399c0ea04d75 100644 --- a/testsuite/tests/safeHaskell/safeLanguage/SafeLang01.hs +++ b/testsuite/tests/safeHaskell/safeLanguage/SafeLang01.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe, TemplateHaskell #-} -- | Test SafeLanguage disables things diff --git a/testsuite/tests/safeHaskell/safeLanguage/SafeLang01.stderr b/testsuite/tests/safeHaskell/safeLanguage/SafeLang01.stderr index 88b5e05ab31e..1fb5ec66bb63 100644 --- a/testsuite/tests/safeHaskell/safeLanguage/SafeLang01.stderr +++ b/testsuite/tests/safeHaskell/safeLanguage/SafeLang01.stderr @@ -1,3 +1,3 @@ -SafeLang01.hs:1:20: - Warning: -XTemplateHaskell is not allowed in Safe Haskell; ignoring -XTemplateHaskell +SafeLang01.hs:2:20: warning: + -XTemplateHaskell is not allowed in Safe Haskell; ignoring -XTemplateHaskell diff --git a/testsuite/tests/safeHaskell/safeLanguage/SafeLang03.hs b/testsuite/tests/safeHaskell/safeLanguage/SafeLang03.hs index 4f3bce7e0a1f..8c73aeaf4166 100644 --- a/testsuite/tests/safeHaskell/safeLanguage/SafeLang03.hs +++ b/testsuite/tests/safeHaskell/safeLanguage/SafeLang03.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} {-# OPTIONS_GHC -fenable-rewrite-rules #-} diff --git a/testsuite/tests/safeHaskell/safeLanguage/SafeLang03.stderr b/testsuite/tests/safeHaskell/safeLanguage/SafeLang03.stderr index 33a66e626747..20d4d174b234 100644 --- a/testsuite/tests/safeHaskell/safeLanguage/SafeLang03.stderr +++ b/testsuite/tests/safeHaskell/safeLanguage/SafeLang03.stderr @@ -1,4 +1,4 @@ -SafeLang03.hs:7:11: Warning: +SafeLang03.hs:8:11: warning: Rule "f" ignored User defined rules are disabled under Safe Haskell diff --git a/testsuite/tests/safeHaskell/safeLanguage/SafeLang08.hs b/testsuite/tests/safeHaskell/safeLanguage/SafeLang08.hs index 7249c8d0ecfb..5cdb87cb1375 100644 --- a/testsuite/tests/safeHaskell/safeLanguage/SafeLang08.hs +++ b/testsuite/tests/safeHaskell/safeLanguage/SafeLang08.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} {-# LANGUAGE ForeignFunctionInterface #-} diff --git a/testsuite/tests/safeHaskell/safeLanguage/SafeLang08.stderr b/testsuite/tests/safeHaskell/safeLanguage/SafeLang08.stderr index ae5d65861924..7e1655e00a65 100644 --- a/testsuite/tests/safeHaskell/safeLanguage/SafeLang08.stderr +++ b/testsuite/tests/safeHaskell/safeLanguage/SafeLang08.stderr @@ -1,7 +1,7 @@ -SafeLang08.hs:9:1: - Unacceptable result type in foreign declaration: - Safe Haskell is on, all FFI imports must be in the IO monad - When checking declaration: - foreign import ccall safe "SafeLang08_A" c_sin - :: CDouble -> CDouble +SafeLang08.hs:10:1: error: + • Unacceptable result type in foreign declaration: + Safe Haskell is on, all FFI imports must be in the IO monad + • When checking declaration: + foreign import ccall safe "SafeLang08_A" c_sin + :: CDouble -> CDouble diff --git a/testsuite/tests/safeHaskell/safeLanguage/SafeLang10.hs b/testsuite/tests/safeHaskell/safeLanguage/SafeLang10.hs index 5c88d3916d48..bafddd068ed9 100644 --- a/testsuite/tests/safeHaskell/safeLanguage/SafeLang10.hs +++ b/testsuite/tests/safeHaskell/safeLanguage/SafeLang10.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Trustworthy #-} module Main where diff --git a/testsuite/tests/safeHaskell/safeLanguage/SafeLang10.stderr b/testsuite/tests/safeHaskell/safeLanguage/SafeLang10.stderr index 557c4f485894..26f04624afee 100644 --- a/testsuite/tests/safeHaskell/safeLanguage/SafeLang10.stderr +++ b/testsuite/tests/safeHaskell/safeLanguage/SafeLang10.stderr @@ -2,19 +2,19 @@ [2 of 3] Compiling SafeLang10_B ( SafeLang10_B.hs, SafeLang10_B.o ) [3 of 3] Compiling Main ( SafeLang10.hs, SafeLang10.o ) -SafeLang10.hs:8:13: - Unsafe overlapping instances for Pos [Int] - arising from a use of ‘res’ - The matching instance is: - instance [overlapping] [safe] Pos [Int] - -- Defined at SafeLang10_B.hs:13:30 - It is compiled in a Safe module and as such can only - overlap instances from the same module, however it - overlaps the following instances from different modules: - instance Pos [a] -- Defined at SafeLang10_A.hs:13:10 - In the expression: res [(1 :: Int)] - In an equation for ‘r’: r = res [(1 :: Int)] - In the expression: - do let r = res ... - putStrLn $ "Result: " ++ show r - putStrLn $ "Result: " ++ show function +SafeLang10.hs:9:13: error: + • Unsafe overlapping instances for Pos [Int] + arising from a use of ‘res’ + The matching instance is: + instance [overlapping] [safe] Pos [Int] + -- Defined at SafeLang10_B.hs:14:30 + It is compiled in a Safe module and as such can only + overlap instances from the same module, however it + overlaps the following instances from different modules: + instance Pos [a] -- Defined at SafeLang10_A.hs:14:10 + • In the expression: res [(1 :: Int)] + In an equation for ‘r’: r = res [(1 :: Int)] + In the expression: + do let r = res ... + putStrLn $ "Result: " ++ show r + putStrLn $ "Result: " ++ show function diff --git a/testsuite/tests/safeHaskell/safeLanguage/SafeLang10_A.hs b/testsuite/tests/safeHaskell/safeLanguage/SafeLang10_A.hs index 7be17b5ec091..9a94458c7e83 100644 --- a/testsuite/tests/safeHaskell/safeLanguage/SafeLang10_A.hs +++ b/testsuite/tests/safeHaskell/safeLanguage/SafeLang10_A.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE FlexibleInstances #-} {-# LANGUAGE Trustworthy #-} diff --git a/testsuite/tests/safeHaskell/safeLanguage/SafeLang10_B.hs b/testsuite/tests/safeHaskell/safeLanguage/SafeLang10_B.hs index d9a8f63f506b..5b9aa814cbc7 100644 --- a/testsuite/tests/safeHaskell/safeLanguage/SafeLang10_B.hs +++ b/testsuite/tests/safeHaskell/safeLanguage/SafeLang10_B.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE FlexibleInstances #-} {-# LANGUAGE Safe #-} diff --git a/testsuite/tests/safeHaskell/safeLanguage/SafeLang12.hs b/testsuite/tests/safeHaskell/safeLanguage/SafeLang12.hs index ba5766b0640c..930257a7e0b3 100644 --- a/testsuite/tests/safeHaskell/safeLanguage/SafeLang12.hs +++ b/testsuite/tests/safeHaskell/safeLanguage/SafeLang12.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} {-# LANGUAGE TemplateHaskell #-} module Main where diff --git a/testsuite/tests/safeHaskell/safeLanguage/SafeLang12.stderr b/testsuite/tests/safeHaskell/safeLanguage/SafeLang12.stderr index c7923a04034b..33bf7ce3fe2c 100644 --- a/testsuite/tests/safeHaskell/safeLanguage/SafeLang12.stderr +++ b/testsuite/tests/safeHaskell/safeLanguage/SafeLang12.stderr @@ -1,8 +1,8 @@ -SafeLang12.hs:2:14: warning: +SafeLang12.hs:3:14: warning: -XTemplateHaskell is not allowed in Safe Haskell; ignoring -XTemplateHaskell -SafeLang12_B.hs:2:14: warning: +SafeLang12_B.hs:3:14: warning: -XTemplateHaskell is not allowed in Safe Haskell; ignoring -XTemplateHaskell [1 of 3] Compiling SafeLang12_A ( SafeLang12_A.hs, SafeLang12_A.o ) [2 of 3] Compiling SafeLang12_B ( SafeLang12_B.hs, SafeLang12_B.o ) diff --git a/testsuite/tests/safeHaskell/safeLanguage/SafeLang12_A.hs b/testsuite/tests/safeHaskell/safeLanguage/SafeLang12_A.hs index 3122859b5912..9d6ce5cdb36c 100644 --- a/testsuite/tests/safeHaskell/safeLanguage/SafeLang12_A.hs +++ b/testsuite/tests/safeHaskell/safeLanguage/SafeLang12_A.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} module SafeLang12_A ( A ) where diff --git a/testsuite/tests/safeHaskell/safeLanguage/SafeLang12_B.hs b/testsuite/tests/safeHaskell/safeLanguage/SafeLang12_B.hs index 7219b7a200f5..50e7930c2d3a 100644 --- a/testsuite/tests/safeHaskell/safeLanguage/SafeLang12_B.hs +++ b/testsuite/tests/safeHaskell/safeLanguage/SafeLang12_B.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} {-# LANGUAGE TemplateHaskell #-} module SafeLang12_B ( Class(..), mkSimpleClass ) where diff --git a/testsuite/tests/safeHaskell/safeLanguage/SafeLang16.hs b/testsuite/tests/safeHaskell/safeLanguage/SafeLang16.hs index 78708da6ac3c..cbcb7a376a42 100644 --- a/testsuite/tests/safeHaskell/safeLanguage/SafeLang16.hs +++ b/testsuite/tests/safeHaskell/safeLanguage/SafeLang16.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TemplateHaskell #-} {-# LANGUAGE Safe #-} diff --git a/testsuite/tests/safeHaskell/safeLanguage/SafeLang16.stderr b/testsuite/tests/safeHaskell/safeLanguage/SafeLang16.stderr index e15b20bb18c5..5aaab72d8a74 100644 --- a/testsuite/tests/safeHaskell/safeLanguage/SafeLang16.stderr +++ b/testsuite/tests/safeHaskell/safeLanguage/SafeLang16.stderr @@ -1,3 +1,3 @@ -SafeLang16.hs:1:14: - Warning: -XTemplateHaskell is not allowed in Safe Haskell; ignoring -XTemplateHaskell +SafeLang16.hs:2:14: warning: + -XTemplateHaskell is not allowed in Safe Haskell; ignoring -XTemplateHaskell diff --git a/testsuite/tests/safeHaskell/safeLanguage/SafeLang17.hs b/testsuite/tests/safeHaskell/safeLanguage/SafeLang17.hs index 411addd00ce9..1fb79da713b0 100644 --- a/testsuite/tests/safeHaskell/safeLanguage/SafeLang17.hs +++ b/testsuite/tests/safeHaskell/safeLanguage/SafeLang17.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Trustworthy #-} module Main where diff --git a/testsuite/tests/safeHaskell/safeLanguage/SafeLang17.stderr b/testsuite/tests/safeHaskell/safeLanguage/SafeLang17.stderr index 358572165452..1aab52a6465a 100644 --- a/testsuite/tests/safeHaskell/safeLanguage/SafeLang17.stderr +++ b/testsuite/tests/safeHaskell/safeLanguage/SafeLang17.stderr @@ -2,19 +2,19 @@ [2 of 3] Compiling SafeLang17_B ( SafeLang17_B.hs, SafeLang17_B.o ) [3 of 3] Compiling Main ( SafeLang17.hs, SafeLang17.o ) -SafeLang17.hs:8:13: - Unsafe overlapping instances for Pos [Int] - arising from a use of ‘res’ - The matching instance is: - instance [incoherent] [safe] Pos [Int] - -- Defined at SafeLang17_B.hs:14:10 - It is compiled in a Safe module and as such can only - overlap instances from the same module, however it - overlaps the following instances from different modules: - instance Pos [a] -- Defined at SafeLang17_A.hs:13:10 - In the expression: res [(1 :: Int)] - In an equation for ‘r’: r = res [(1 :: Int)] - In the expression: - do let r = res ... - putStrLn $ "Result: " ++ show r - putStrLn $ "Result: " ++ show function +SafeLang17.hs:9:13: error: + • Unsafe overlapping instances for Pos [Int] + arising from a use of ‘res’ + The matching instance is: + instance [incoherent] [safe] Pos [Int] + -- Defined at SafeLang17_B.hs:15:10 + It is compiled in a Safe module and as such can only + overlap instances from the same module, however it + overlaps the following instances from different modules: + instance Pos [a] -- Defined at SafeLang17_A.hs:14:10 + • In the expression: res [(1 :: Int)] + In an equation for ‘r’: r = res [(1 :: Int)] + In the expression: + do let r = res ... + putStrLn $ "Result: " ++ show r + putStrLn $ "Result: " ++ show function diff --git a/testsuite/tests/safeHaskell/safeLanguage/SafeLang17_A.hs b/testsuite/tests/safeHaskell/safeLanguage/SafeLang17_A.hs index 0ce2bdf6b9de..ef506e3b57d0 100644 --- a/testsuite/tests/safeHaskell/safeLanguage/SafeLang17_A.hs +++ b/testsuite/tests/safeHaskell/safeLanguage/SafeLang17_A.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Trustworthy #-} {-# LANGUAGE FlexibleInstances #-} diff --git a/testsuite/tests/safeHaskell/safeLanguage/SafeLang17_B.hs b/testsuite/tests/safeHaskell/safeLanguage/SafeLang17_B.hs index 2059f0152367..b18192c0fbaa 100644 --- a/testsuite/tests/safeHaskell/safeLanguage/SafeLang17_B.hs +++ b/testsuite/tests/safeHaskell/safeLanguage/SafeLang17_B.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} {-# LANGUAGE FlexibleInstances #-} {-# LANGUAGE IncoherentInstances #-} diff --git a/testsuite/tests/safeHaskell/safeLanguage/SafeLang18.hs b/testsuite/tests/safeHaskell/safeLanguage/SafeLang18.hs index 330a80d069fb..ad11681da889 100644 --- a/testsuite/tests/safeHaskell/safeLanguage/SafeLang18.hs +++ b/testsuite/tests/safeHaskell/safeLanguage/SafeLang18.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE CPP #-} #if __GLASGOW_HASKELL__ >= 703 {-# LANGUAGE Safe #-} diff --git a/testsuite/tests/safeHaskell/unsafeLibs/BadImport01.hs b/testsuite/tests/safeHaskell/unsafeLibs/BadImport01.hs index 175365c17cdd..d1026ea55f4d 100644 --- a/testsuite/tests/safeHaskell/unsafeLibs/BadImport01.hs +++ b/testsuite/tests/safeHaskell/unsafeLibs/BadImport01.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} -- | Import unsafe module System.IO.Unsafe to make sure it fails module Main where diff --git a/testsuite/tests/safeHaskell/unsafeLibs/BadImport01.stderr b/testsuite/tests/safeHaskell/unsafeLibs/BadImport01.stderr index 7c5128d7e245..8afd025680ec 100644 --- a/testsuite/tests/safeHaskell/unsafeLibs/BadImport01.stderr +++ b/testsuite/tests/safeHaskell/unsafeLibs/BadImport01.stderr @@ -1,4 +1,4 @@ -BadImport01.hs:5:1: +BadImport01.hs:6:1: error: System.IO.Unsafe: Can't be safely imported! The module itself isn't safe. diff --git a/testsuite/tests/safeHaskell/unsafeLibs/BadImport06.hs b/testsuite/tests/safeHaskell/unsafeLibs/BadImport06.hs index e64a7ea09b16..d912b7da7356 100644 --- a/testsuite/tests/safeHaskell/unsafeLibs/BadImport06.hs +++ b/testsuite/tests/safeHaskell/unsafeLibs/BadImport06.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} -- | Import unsafe module Debug.Trace to make sure it fails module Main where diff --git a/testsuite/tests/safeHaskell/unsafeLibs/BadImport06.stderr b/testsuite/tests/safeHaskell/unsafeLibs/BadImport06.stderr index 51a5bebec326..06995b8f2cc2 100644 --- a/testsuite/tests/safeHaskell/unsafeLibs/BadImport06.stderr +++ b/testsuite/tests/safeHaskell/unsafeLibs/BadImport06.stderr @@ -1,4 +1,4 @@ -BadImport06.hs:5:1: +BadImport06.hs:6:1: error: Debug.Trace: Can't be safely imported! The module itself isn't safe. diff --git a/testsuite/tests/safeHaskell/unsafeLibs/BadImport07.hs b/testsuite/tests/safeHaskell/unsafeLibs/BadImport07.hs index da0f440a5097..5e29dad2bba1 100644 --- a/testsuite/tests/safeHaskell/unsafeLibs/BadImport07.hs +++ b/testsuite/tests/safeHaskell/unsafeLibs/BadImport07.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} -- | Import unsafe module Unsafe.Coerce to make sure it fails module Main where diff --git a/testsuite/tests/safeHaskell/unsafeLibs/BadImport07.stderr b/testsuite/tests/safeHaskell/unsafeLibs/BadImport07.stderr index 5133f045ece8..4782befae7c2 100644 --- a/testsuite/tests/safeHaskell/unsafeLibs/BadImport07.stderr +++ b/testsuite/tests/safeHaskell/unsafeLibs/BadImport07.stderr @@ -1,4 +1,4 @@ -BadImport07.hs:5:1: +BadImport07.hs:6:1: error: Unsafe.Coerce: Can't be safely imported! The module itself isn't safe. diff --git a/testsuite/tests/safeHaskell/unsafeLibs/BadImport08.hs b/testsuite/tests/safeHaskell/unsafeLibs/BadImport08.hs index d2688fab80bb..338e1e13df08 100644 --- a/testsuite/tests/safeHaskell/unsafeLibs/BadImport08.hs +++ b/testsuite/tests/safeHaskell/unsafeLibs/BadImport08.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} -- | Import unsafe module Control.ST to make sure it fails module Main where diff --git a/testsuite/tests/safeHaskell/unsafeLibs/BadImport08.stderr b/testsuite/tests/safeHaskell/unsafeLibs/BadImport08.stderr index aa8b5a57f4fe..5c45d2ab6af4 100644 --- a/testsuite/tests/safeHaskell/unsafeLibs/BadImport08.stderr +++ b/testsuite/tests/safeHaskell/unsafeLibs/BadImport08.stderr @@ -1,4 +1,4 @@ -BadImport08.hs:5:1: +BadImport08.hs:6:1: error: Control.Monad.ST.Unsafe: Can't be safely imported! The module itself isn't safe. diff --git a/testsuite/tests/safeHaskell/unsafeLibs/BadImport09.hs b/testsuite/tests/safeHaskell/unsafeLibs/BadImport09.hs index 90d1c49090a1..2db8642d464e 100644 --- a/testsuite/tests/safeHaskell/unsafeLibs/BadImport09.hs +++ b/testsuite/tests/safeHaskell/unsafeLibs/BadImport09.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} -- | Import unsafe module Control.ST to make sure it fails module Main where diff --git a/testsuite/tests/safeHaskell/unsafeLibs/BadImport09.stderr b/testsuite/tests/safeHaskell/unsafeLibs/BadImport09.stderr index 88556c89976c..91611c0fcc56 100644 --- a/testsuite/tests/safeHaskell/unsafeLibs/BadImport09.stderr +++ b/testsuite/tests/safeHaskell/unsafeLibs/BadImport09.stderr @@ -1,4 +1,4 @@ -BadImport09.hs:5:1: +BadImport09.hs:6:1: error: Control.Monad.ST.Lazy.Unsafe: Can't be safely imported! The module itself isn't safe. diff --git a/testsuite/tests/safeHaskell/unsafeLibs/Dep05.hs b/testsuite/tests/safeHaskell/unsafeLibs/Dep05.hs index 1d64daa5ae92..1d868c3e9e42 100644 --- a/testsuite/tests/safeHaskell/unsafeLibs/Dep05.hs +++ b/testsuite/tests/safeHaskell/unsafeLibs/Dep05.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} {-# LANGUAGE NoMonomorphismRestriction #-} {-# LANGUAGE UnboxedTuples #-} diff --git a/testsuite/tests/safeHaskell/unsafeLibs/Dep05.stderr b/testsuite/tests/safeHaskell/unsafeLibs/Dep05.stderr index 4c93c907e8b7..fb3cb5eecddb 100644 --- a/testsuite/tests/safeHaskell/unsafeLibs/Dep05.stderr +++ b/testsuite/tests/safeHaskell/unsafeLibs/Dep05.stderr @@ -1,3 +1,3 @@ -Dep05.hs:6:1: error: +Dep05.hs:7:1: error: GHC.Arr: Can't be safely imported! The module itself isn't safe. diff --git a/testsuite/tests/safeHaskell/unsafeLibs/Dep06.hs b/testsuite/tests/safeHaskell/unsafeLibs/Dep06.hs index 2dbb15e19722..42da25b2f31d 100644 --- a/testsuite/tests/safeHaskell/unsafeLibs/Dep06.hs +++ b/testsuite/tests/safeHaskell/unsafeLibs/Dep06.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} module Dep06 where diff --git a/testsuite/tests/safeHaskell/unsafeLibs/Dep06.stderr b/testsuite/tests/safeHaskell/unsafeLibs/Dep06.stderr index ae8bdf8fd6a6..7824935d9180 100644 --- a/testsuite/tests/safeHaskell/unsafeLibs/Dep06.stderr +++ b/testsuite/tests/safeHaskell/unsafeLibs/Dep06.stderr @@ -1,3 +1,3 @@ -Dep06.hs:4:1: +Dep06.hs:5:1: error: GHC.Conc: Can't be safely imported! The module itself isn't safe. diff --git a/testsuite/tests/safeHaskell/unsafeLibs/Dep07.hs b/testsuite/tests/safeHaskell/unsafeLibs/Dep07.hs index 662b6a475459..0a2309190eab 100644 --- a/testsuite/tests/safeHaskell/unsafeLibs/Dep07.hs +++ b/testsuite/tests/safeHaskell/unsafeLibs/Dep07.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} module Dep07 where diff --git a/testsuite/tests/safeHaskell/unsafeLibs/Dep07.stderr b/testsuite/tests/safeHaskell/unsafeLibs/Dep07.stderr index dcc7c4849d5a..cf79a18f6ed8 100644 --- a/testsuite/tests/safeHaskell/unsafeLibs/Dep07.stderr +++ b/testsuite/tests/safeHaskell/unsafeLibs/Dep07.stderr @@ -1,4 +1,4 @@ -Dep07.hs:4:1: +Dep07.hs:5:1: error: GHC.ForeignPtr: Can't be safely imported! The module itself isn't safe. diff --git a/testsuite/tests/safeHaskell/unsafeLibs/Dep08.hs b/testsuite/tests/safeHaskell/unsafeLibs/Dep08.hs index 76a0dde570a9..19bf730952f2 100644 --- a/testsuite/tests/safeHaskell/unsafeLibs/Dep08.hs +++ b/testsuite/tests/safeHaskell/unsafeLibs/Dep08.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} {-# LANGUAGE NoMonomorphismRestriction #-} module Dep08 where diff --git a/testsuite/tests/safeHaskell/unsafeLibs/Dep08.stderr b/testsuite/tests/safeHaskell/unsafeLibs/Dep08.stderr index 386f6412c382..09fa7d86ee73 100644 --- a/testsuite/tests/safeHaskell/unsafeLibs/Dep08.stderr +++ b/testsuite/tests/safeHaskell/unsafeLibs/Dep08.stderr @@ -1,4 +1,4 @@ -Dep08.hs:5:1: +Dep08.hs:6:1: error: GHC.IOArray: Can't be safely imported! The module itself isn't safe. diff --git a/testsuite/tests/safeHaskell/unsafeLibs/Dep09.hs b/testsuite/tests/safeHaskell/unsafeLibs/Dep09.hs index a92f739b50ca..a5808d4680b6 100644 --- a/testsuite/tests/safeHaskell/unsafeLibs/Dep09.hs +++ b/testsuite/tests/safeHaskell/unsafeLibs/Dep09.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} module Dep09 where diff --git a/testsuite/tests/safeHaskell/unsafeLibs/Dep09.stderr b/testsuite/tests/safeHaskell/unsafeLibs/Dep09.stderr index 76606c2e401e..4c776d383298 100644 --- a/testsuite/tests/safeHaskell/unsafeLibs/Dep09.stderr +++ b/testsuite/tests/safeHaskell/unsafeLibs/Dep09.stderr @@ -1,3 +1,3 @@ -Dep09.hs:4:1: +Dep09.hs:5:1: error: GHC.Ptr: Can't be safely imported! The module itself isn't safe. diff --git a/testsuite/tests/safeHaskell/unsafeLibs/Dep10.hs b/testsuite/tests/safeHaskell/unsafeLibs/Dep10.hs index 84a7adcff7d4..61dad2505d99 100644 --- a/testsuite/tests/safeHaskell/unsafeLibs/Dep10.hs +++ b/testsuite/tests/safeHaskell/unsafeLibs/Dep10.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} module Dep10 where diff --git a/testsuite/tests/safeHaskell/unsafeLibs/Dep10.stderr b/testsuite/tests/safeHaskell/unsafeLibs/Dep10.stderr index 68fe214bc816..af1627c985fa 100644 --- a/testsuite/tests/safeHaskell/unsafeLibs/Dep10.stderr +++ b/testsuite/tests/safeHaskell/unsafeLibs/Dep10.stderr @@ -1,3 +1,3 @@ -Dep10.hs:4:1: +Dep10.hs:5:1: error: GHC.ST: Can't be safely imported! The module itself isn't safe. diff --git a/testsuite/tests/safeHaskell/unsafeLibs/GoodImport01.hs b/testsuite/tests/safeHaskell/unsafeLibs/GoodImport01.hs index 7834de52bccc..276f183a5918 100644 --- a/testsuite/tests/safeHaskell/unsafeLibs/GoodImport01.hs +++ b/testsuite/tests/safeHaskell/unsafeLibs/GoodImport01.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} -- | Import SYB stuff that should be safe module Main where diff --git a/testsuite/tests/safeHaskell/unsafeLibs/GoodImport02.hs b/testsuite/tests/safeHaskell/unsafeLibs/GoodImport02.hs index 86c34adb0dd6..c8ebcd483345 100644 --- a/testsuite/tests/safeHaskell/unsafeLibs/GoodImport02.hs +++ b/testsuite/tests/safeHaskell/unsafeLibs/GoodImport02.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} -- | Import (now safe by default) modules. module Main where diff --git a/testsuite/tests/safeHaskell/unsafeLibs/GoodImport03.hs b/testsuite/tests/safeHaskell/unsafeLibs/GoodImport03.hs index 2ea80fbd09ef..2a89ee2d91c2 100644 --- a/testsuite/tests/safeHaskell/unsafeLibs/GoodImport03.hs +++ b/testsuite/tests/safeHaskell/unsafeLibs/GoodImport03.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE Safe #-} {-# OPTIONS_GHC -fno-warn-deprecations #-} -- | Import all modules from prelude that should be safe diff --git a/testsuite/tests/saks/should_fail/saks_fail001.hs b/testsuite/tests/saks/should_fail/saks_fail001.hs index c71f7a4a686e..2adfa3a3a795 100644 --- a/testsuite/tests/saks/should_fail/saks_fail001.hs +++ b/testsuite/tests/saks/should_fail/saks_fail001.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} -- No -XStandaloneKindSignatures! module SAKS_Fail001 where diff --git a/testsuite/tests/saks/should_fail/saks_fail001.stderr b/testsuite/tests/saks/should_fail/saks_fail001.stderr index 81ab28278da2..ed20d70860bc 100644 --- a/testsuite/tests/saks/should_fail/saks_fail001.stderr +++ b/testsuite/tests/saks/should_fail/saks_fail001.stderr @@ -1,4 +1,4 @@ -saks_fail001.hs:7:1: error: +saks_fail001.hs:8:1: error: Illegal standalone kind signature Did you mean to enable StandaloneKindSignatures? diff --git a/testsuite/tests/simplCore/should_compile/T14270a.hs b/testsuite/tests/simplCore/should_compile/T14270a.hs index b69de35eecbf..1cf422f709d5 100644 --- a/testsuite/tests/simplCore/should_compile/T14270a.hs +++ b/testsuite/tests/simplCore/should_compile/T14270a.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeApplications, ScopedTypeVariables, GADTs, RankNTypes, PolyKinds, KindSignatures #-} {-# OPTIONS_GHC -O2 #-} -- We are provoking a bug in GHC.Core.Opt.SpecConstr diff --git a/testsuite/tests/simplCore/should_compile/T16038/A.hs b/testsuite/tests/simplCore/should_compile/T16038/A.hs index 3e5137bf9472..5bff464334d3 100644 --- a/testsuite/tests/simplCore/should_compile/T16038/A.hs +++ b/testsuite/tests/simplCore/should_compile/T16038/A.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module A where import B diff --git a/testsuite/tests/simplCore/should_compile/T16038/A.hs-boot b/testsuite/tests/simplCore/should_compile/T16038/A.hs-boot index 48f6768e390b..bad91fcdd0c3 100644 --- a/testsuite/tests/simplCore/should_compile/T16038/A.hs-boot +++ b/testsuite/tests/simplCore/should_compile/T16038/A.hs-boot @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module A where data HsExpr i diff --git a/testsuite/tests/simplCore/should_compile/T16038/B.hs b/testsuite/tests/simplCore/should_compile/T16038/B.hs index 9eb315a41972..98ab2d7ee6a4 100644 --- a/testsuite/tests/simplCore/should_compile/T16038/B.hs +++ b/testsuite/tests/simplCore/should_compile/T16038/B.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module B where import {-# SOURCE #-} A (HsExpr) diff --git a/testsuite/tests/simplCore/should_compile/T16979b.hs b/testsuite/tests/simplCore/should_compile/T16979b.hs index d2b5712674e0..92c6d28a07ee 100644 --- a/testsuite/tests/simplCore/should_compile/T16979b.hs +++ b/testsuite/tests/simplCore/should_compile/T16979b.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE AllowAmbiguousTypes #-} {-# LANGUAGE DataKinds #-} {-# LANGUAGE DeriveGeneric #-} diff --git a/testsuite/tests/simplCore/should_compile/T5329.hs b/testsuite/tests/simplCore/should_compile/T5329.hs index f68110357844..3c14ee8132f3 100644 --- a/testsuite/tests/simplCore/should_compile/T5329.hs +++ b/testsuite/tests/simplCore/should_compile/T5329.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# OPTIONS_GHC -fno-warn-redundant-constraints #-} {-# LANGUAGE UnicodeSyntax #-} {-# LANGUAGE EmptyDataDecls #-} diff --git a/testsuite/tests/simplCore/should_compile/T8331.stderr b/testsuite/tests/simplCore/should_compile/T8331.stderr index 1c510374811c..0fbd7a577ce4 100644 --- a/testsuite/tests/simplCore/should_compile/T8331.stderr +++ b/testsuite/tests/simplCore/should_compile/T8331.stderr @@ -7,7 +7,7 @@ = (useAbstractMonad1 @s) `cast` (<Int>_R %<'Many>_N ->_R <Int>_R %<'Many>_N ->_R Sym (N:ST[0] <s>_N <Int>_R) - ; Sym (N:ReaderT[0] <Int>_R <ST s>_R <Int>_N) + ; Sym (N:ReaderT[0] <*>_N <Int>_R <ST s>_R <Int>_N) :: Coercible (Int -> Int -> STRep s Int) (Int -> ReaderT Int (ST s) Int)) diff --git a/testsuite/tests/simplCore/should_compile/rule2.hs b/testsuite/tests/simplCore/should_compile/rule2.hs index 2b091de5e96e..97b50b92d978 100644 --- a/testsuite/tests/simplCore/should_compile/rule2.hs +++ b/testsuite/tests/simplCore/should_compile/rule2.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE RankNTypes #-} {-# OPTIONS_GHC -ddump-simpl-stats #-} diff --git a/testsuite/tests/simplCore/should_run/T5315.hs b/testsuite/tests/simplCore/should_run/T5315.hs index 5b2ff393466f..6af1fa2332b0 100644 --- a/testsuite/tests/simplCore/should_run/T5315.hs +++ b/testsuite/tests/simplCore/should_run/T5315.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE UnicodeSyntax #-} {-# LANGUAGE EmptyDataDecls #-} {-# LANGUAGE TypeOperators #-} diff --git a/testsuite/tests/simplCore/should_run/runST.hs b/testsuite/tests/simplCore/should_run/runST.hs index dc06c243cf71..0357778ce239 100644 --- a/testsuite/tests/simplCore/should_run/runST.hs +++ b/testsuite/tests/simplCore/should_run/runST.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} import Control.Monad.ST import Data.STRef @@ -7,7 +8,7 @@ import Data.STRef main = let f () = runST $ do - ref <- newSTRef 0 - modifySTRef ref (+1) - readSTRef ref + ref <- newSTRef 0 + modifySTRef ref (+1) + readSTRef ref in print (f () + f ()) diff --git a/testsuite/tests/stranal/should_compile/T8743.hs b/testsuite/tests/stranal/should_compile/T8743.hs index 80c850f14357..1feda6ddbbd5 100644 --- a/testsuite/tests/stranal/should_compile/T8743.hs +++ b/testsuite/tests/stranal/should_compile/T8743.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module T8743 where -- Without the following import, it does not fail diff --git a/testsuite/tests/stranal/should_compile/T8743.hs-boot b/testsuite/tests/stranal/should_compile/T8743.hs-boot index 7f22b248c281..f98c48204a69 100644 --- a/testsuite/tests/stranal/should_compile/T8743.hs-boot +++ b/testsuite/tests/stranal/should_compile/T8743.hs-boot @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module T8743 where class ToRow a instance ToRow (Maybe a) diff --git a/testsuite/tests/stranal/should_compile/T8743a.hs b/testsuite/tests/stranal/should_compile/T8743a.hs index 23b3b7bc5e88..531fa9efaa25 100644 --- a/testsuite/tests/stranal/should_compile/T8743a.hs +++ b/testsuite/tests/stranal/should_compile/T8743a.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module T8743a where import {-# SOURCE #-} T8743 () diff --git a/testsuite/tests/th/ClosedFam2TH.hs b/testsuite/tests/th/ClosedFam2TH.hs index f1e5eee9c0de..43ccf216f8b6 100644 --- a/testsuite/tests/th/ClosedFam2TH.hs +++ b/testsuite/tests/th/ClosedFam2TH.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TemplateHaskell, TypeFamilies, PolyKinds, TypeApplications, TypeFamilyDependencies #-} module ClosedFam2 where diff --git a/testsuite/tests/th/T10811.hs b/testsuite/tests/th/T10811.hs index 3fac1905d6ce..cad100aad5a7 100644 --- a/testsuite/tests/th/T10811.hs +++ b/testsuite/tests/th/T10811.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TemplateHaskell, TypeFamilies #-} module Bug where diff --git a/testsuite/tests/th/T10820.hs b/testsuite/tests/th/T10820.hs index 0e53bbde7221..d981afd00a24 100644 --- a/testsuite/tests/th/T10820.hs +++ b/testsuite/tests/th/T10820.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE LiberalTypeSynonyms #-} {-# LANGUAGE RankNTypes #-} {-# LANGUAGE TemplateHaskell #-} diff --git a/testsuite/tests/th/T10891.hs b/testsuite/tests/th/T10891.hs index 030c5ebb1070..266d5d98aaf2 100644 --- a/testsuite/tests/th/T10891.hs +++ b/testsuite/tests/th/T10891.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies #-} module T10891 where diff --git a/testsuite/tests/th/T11721_TH.hs b/testsuite/tests/th/T11721_TH.hs index b8e895c155a3..a0624274529e 100644 --- a/testsuite/tests/th/T11721_TH.hs +++ b/testsuite/tests/th/T11721_TH.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE GADTs #-} {-# LANGUAGE ScopedTypeVariables #-} {-# LANGUAGE TemplateHaskell #-} diff --git a/testsuite/tests/th/T12045TH1.hs b/testsuite/tests/th/T12045TH1.hs index c16bab29f99c..d8b9e00bf33c 100644 --- a/testsuite/tests/th/T12045TH1.hs +++ b/testsuite/tests/th/T12045TH1.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TemplateHaskell, DataKinds, PolyKinds , TypeInType, TypeApplications, TypeFamilies #-} diff --git a/testsuite/tests/th/T12045TH1.stderr b/testsuite/tests/th/T12045TH1.stderr index 2b856434d5eb..fd727295eb97 100644 --- a/testsuite/tests/th/T12045TH1.stderr +++ b/testsuite/tests/th/T12045TH1.stderr @@ -1,4 +1,4 @@ -T12045TH1.hs:(8,2)-(10,53): Splicing declarations +T12045TH1.hs:(9,2)-(11,53): Splicing declarations [d| type family F (a :: k) :: Type where F @Type Int = Bool F @(Type -> Type) Maybe = Char |] @@ -6,13 +6,13 @@ T12045TH1.hs:(8,2)-(10,53): Splicing declarations type family F (a :: k) :: Type where F @Type Int = Bool F @(Type -> Type) Maybe = Char -T12045TH1.hs:13:2-32: Splicing declarations +T12045TH1.hs:14:2-32: Splicing declarations [d| data family D (a :: k) |] ======> data family D (a :: k) -T12045TH1.hs:15:2-41: Splicing declarations +T12045TH1.hs:16:2-41: Splicing declarations [d| data instance D @Type a = DBool |] ======> data instance D @Type a = DBool -T12045TH1.hs:17:2-51: Splicing declarations +T12045TH1.hs:18:2-51: Splicing declarations [d| data instance D @(Type -> Type) b = DChar |] ======> data instance D @(Type -> Type) b = DChar diff --git a/testsuite/tests/th/T12045TH2.hs b/testsuite/tests/th/T12045TH2.hs index 21d04cb826ff..cab400d301ca 100644 --- a/testsuite/tests/th/T12045TH2.hs +++ b/testsuite/tests/th/T12045TH2.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TemplateHaskell, TypeApplications, PolyKinds , TypeFamilies, DataKinds #-} diff --git a/testsuite/tests/th/T12411.hs b/testsuite/tests/th/T12411.hs index fd8f9db8f384..2b52e0169446 100644 --- a/testsuite/tests/th/T12411.hs +++ b/testsuite/tests/th/T12411.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TemplateHaskell #-} module T12411 where diff --git a/testsuite/tests/th/T12411.stderr b/testsuite/tests/th/T12411.stderr index 22f7de019098..79172a1a4637 100644 --- a/testsuite/tests/th/T12411.stderr +++ b/testsuite/tests/th/T12411.stderr @@ -1,6 +1,6 @@ -T12411.hs:4:1: error: +T12411.hs:5:1: error: Illegal visible type application ‘@Q’ Perhaps you intended to use TypeApplications -T12411.hs:4:7: error: Not in scope: type constructor or class ‘Q’ +T12411.hs:5:7: error: Not in scope: type constructor or class ‘Q’ diff --git a/testsuite/tests/th/T12646.hs b/testsuite/tests/th/T12646.hs index b3ba86e54c9b..aa33f5cb058b 100644 --- a/testsuite/tests/th/T12646.hs +++ b/testsuite/tests/th/T12646.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE PolyKinds #-} {-# LANGUAGE TemplateHaskell #-} {-# LANGUAGE TypeFamilies #-} diff --git a/testsuite/tests/th/T15243.hs b/testsuite/tests/th/T15243.hs index 8b366404c89e..c429f783aaeb 100644 --- a/testsuite/tests/th/T15243.hs +++ b/testsuite/tests/th/T15243.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE DataKinds #-} {-# LANGUAGE PolyKinds #-} {-# LANGUAGE TemplateHaskell #-} diff --git a/testsuite/tests/th/T15243.stderr b/testsuite/tests/th/T15243.stderr index 4cf78cacd6ca..74f316e7d7a6 100644 --- a/testsuite/tests/th/T15243.stderr +++ b/testsuite/tests/th/T15243.stderr @@ -1,4 +1,4 @@ -T15243.hs:(10,2)-(15,7): Splicing declarations +T15243.hs:(11,2)-(16,7): Splicing declarations [d| type family F (a :: k) :: k where F 'Unit = 'Unit F '(,) = '(,) diff --git a/testsuite/tests/th/T16133.hs b/testsuite/tests/th/T16133.hs index b7f5e23d092e..e650042b7a86 100644 --- a/testsuite/tests/th/T16133.hs +++ b/testsuite/tests/th/T16133.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE PolyKinds #-} {-# LANGUAGE TemplateHaskell #-} module T16133 where diff --git a/testsuite/tests/th/T16133.stderr b/testsuite/tests/th/T16133.stderr index 3a9b9f7480c5..840f9f066fec 100644 --- a/testsuite/tests/th/T16133.stderr +++ b/testsuite/tests/th/T16133.stderr @@ -1,9 +1,8 @@ -T16133.hs:10:2: error: +T16133.hs:11:2: error: Illegal visible type application ‘@Int’ Perhaps you intended to use TypeApplications -T16133.hs:10:2: error: +T16133.hs:11:2: error: Illegal visible kind application ‘@Type’ Perhaps you intended to use TypeApplications - diff --git a/testsuite/tests/th/T16976.hs b/testsuite/tests/th/T16976.hs index 4d2c88979469..862419d34879 100644 --- a/testsuite/tests/th/T16976.hs +++ b/testsuite/tests/th/T16976.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE PatternSynonyms #-} {-# LANGUAGE NoMonomorphismRestriction #-} diff --git a/testsuite/tests/th/T18388.hs b/testsuite/tests/th/T18388.hs index d31758004b23..a5975a6eb59a 100644 --- a/testsuite/tests/th/T18388.hs +++ b/testsuite/tests/th/T18388.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE DerivingVia #-} {-# LANGUAGE FlexibleInstances #-} {-# LANGUAGE MultiParamTypeClasses #-} diff --git a/testsuite/tests/th/TH_Roles4.hs b/testsuite/tests/th/TH_Roles4.hs index 16dbb6710278..c081c73588ef 100644 --- a/testsuite/tests/th/TH_Roles4.hs +++ b/testsuite/tests/th/TH_Roles4.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TemplateHaskell #-} module Roles4 where diff --git a/testsuite/tests/th/TH_reifyExplicitForAllFams.hs b/testsuite/tests/th/TH_reifyExplicitForAllFams.hs index 60a6d4563fff..f242144404c1 100644 --- a/testsuite/tests/th/TH_reifyExplicitForAllFams.hs +++ b/testsuite/tests/th/TH_reifyExplicitForAllFams.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} -- test reification of explicit foralls in type families {-# LANGUAGE TypeFamilies, ExplicitForAll #-} diff --git a/testsuite/tests/typecheck/should_compile/LocalGivenEqs.hs b/testsuite/tests/typecheck/should_compile/LocalGivenEqs.hs index f1280205b2a9..fd37ede0dbb3 100644 --- a/testsuite/tests/typecheck/should_compile/LocalGivenEqs.hs +++ b/testsuite/tests/typecheck/should_compile/LocalGivenEqs.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE RankNTypes, TypeFamilies, FlexibleInstances #-} {-# OPTIONS_GHC -Wno-missing-methods -Wno-unused-matches #-} diff --git a/testsuite/tests/typecheck/should_compile/SplitWD.hs b/testsuite/tests/typecheck/should_compile/SplitWD.hs index 5281cdbf0e16..b0f37cc4b1ce 100644 --- a/testsuite/tests/typecheck/should_compile/SplitWD.hs +++ b/testsuite/tests/typecheck/should_compile/SplitWD.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE ScopedTypeVariables, TypeOperators, DataKinds, PolyKinds, TypeFamilies, GADTs, StandaloneDeriving #-} diff --git a/testsuite/tests/typecheck/should_compile/T11524.hs b/testsuite/tests/typecheck/should_compile/T11524.hs index d6e2adf4f468..0856afe50be1 100644 --- a/testsuite/tests/typecheck/should_compile/T11524.hs +++ b/testsuite/tests/typecheck/should_compile/T11524.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE GADTs #-} {-# LANGUAGE PolyKinds #-} {-# LANGUAGE ExplicitForAll #-} diff --git a/testsuite/tests/typecheck/should_compile/T11811.hs b/testsuite/tests/typecheck/should_compile/T11811.hs index e3e0f810b3ca..5387ef62a5da 100644 --- a/testsuite/tests/typecheck/should_compile/T11811.hs +++ b/testsuite/tests/typecheck/should_compile/T11811.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE PolyKinds, GADTs #-} module T11811 where diff --git a/testsuite/tests/typecheck/should_compile/T12919.hs b/testsuite/tests/typecheck/should_compile/T12919.hs index 778abfa1e7cc..29eb9dc469b0 100644 --- a/testsuite/tests/typecheck/should_compile/T12919.hs +++ b/testsuite/tests/typecheck/should_compile/T12919.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE DataKinds, PolyKinds, TypeFamilies, GADTs, ConstraintKinds #-} module T12919 where diff --git a/testsuite/tests/typecheck/should_compile/T13333.hs b/testsuite/tests/typecheck/should_compile/T13333.hs index 9a84e87265a6..843b3d816502 100644 --- a/testsuite/tests/typecheck/should_compile/T13333.hs +++ b/testsuite/tests/typecheck/should_compile/T13333.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE ConstraintKinds #-} {-# LANGUAGE FlexibleContexts #-} {-# LANGUAGE GADTs #-} diff --git a/testsuite/tests/typecheck/should_compile/T13651.hs b/testsuite/tests/typecheck/should_compile/T13651.hs index 57e627aa71b6..a426cb55432a 100644 --- a/testsuite/tests/typecheck/should_compile/T13651.hs +++ b/testsuite/tests/typecheck/should_compile/T13651.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies, TypeFamilyDependencies #-} module T13651 where diff --git a/testsuite/tests/typecheck/should_compile/T13651.stderr b/testsuite/tests/typecheck/should_compile/T13651.stderr index cc7af849d313..99d57d1c96ff 100644 --- a/testsuite/tests/typecheck/should_compile/T13651.stderr +++ b/testsuite/tests/typecheck/should_compile/T13651.stderr @@ -1,5 +1,5 @@ -T13651.hs:11:8: error: +T13651.hs:12:8: error: • Could not deduce: F cr (Bar h (Foo u)) ~ Bar h (Bar r u) from the context: (F cr cu ~ Bar h (Bar r u), F cu cs ~ Bar (Foo h) (Bar u s)) @@ -7,7 +7,7 @@ T13651.hs:11:8: error: foo :: forall cr cu h r u cs s. (F cr cu ~ Bar h (Bar r u), F cu cs ~ Bar (Foo h) (Bar u s)) => Bar h (Bar r u) -> Bar (Foo h) (Bar u s) -> Foo (cr -> cs) - at T13651.hs:(11,8)-(13,65) + at T13651.hs:(12,8)-(14,65) Expected: forall cr cu h r u cs s. (F cr cu ~ Bar h (Bar r u), F cu cs ~ Bar (Foo h) (Bar u s)) => Bar h (Bar r u) -> Bar (Foo h) (Bar u s) -> Foo (cr -> cs) diff --git a/testsuite/tests/typecheck/should_compile/T13651a.hs b/testsuite/tests/typecheck/should_compile/T13651a.hs index 482231b6f262..f08407b7385a 100644 --- a/testsuite/tests/typecheck/should_compile/T13651a.hs +++ b/testsuite/tests/typecheck/should_compile/T13651a.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies, TypeFamilyDependencies #-} module T13651 where diff --git a/testsuite/tests/typecheck/should_compile/T13822.hs b/testsuite/tests/typecheck/should_compile/T13822.hs index 5c4d51382ffa..cd5ff23478ec 100644 --- a/testsuite/tests/typecheck/should_compile/T13822.hs +++ b/testsuite/tests/typecheck/should_compile/T13822.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE GADTs, TypeOperators, PolyKinds, DataKinds, TypeFamilyDependencies, RankNTypes, LambdaCase, EmptyCase, UndecidableInstances #-} diff --git a/testsuite/tests/typecheck/should_compile/T13871.hs b/testsuite/tests/typecheck/should_compile/T13871.hs index 623923eacae1..fa233247ca3c 100644 --- a/testsuite/tests/typecheck/should_compile/T13871.hs +++ b/testsuite/tests/typecheck/should_compile/T13871.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE ConstraintKinds #-} {-# LANGUAGE GADTs #-} {-# LANGUAGE TypeFamilies #-} diff --git a/testsuite/tests/typecheck/should_compile/T13879.hs b/testsuite/tests/typecheck/should_compile/T13879.hs index 2e10c472fb29..8a70565e7a4d 100644 --- a/testsuite/tests/typecheck/should_compile/T13879.hs +++ b/testsuite/tests/typecheck/should_compile/T13879.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE GADTs #-} {-# LANGUAGE RankNTypes #-} {-# LANGUAGE ScopedTypeVariables #-} diff --git a/testsuite/tests/typecheck/should_compile/T14366.hs b/testsuite/tests/typecheck/should_compile/T14366.hs index 56abad5d30d4..9405c9b91bec 100644 --- a/testsuite/tests/typecheck/should_compile/T14366.hs +++ b/testsuite/tests/typecheck/should_compile/T14366.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies #-} {-# LANGUAGE TypeInType #-} {-# LANGUAGE TypeOperators #-} diff --git a/testsuite/tests/typecheck/should_compile/T14451.hs b/testsuite/tests/typecheck/should_compile/T14451.hs index a67ce74537a6..40f03e3ece59 100644 --- a/testsuite/tests/typecheck/should_compile/T14451.hs +++ b/testsuite/tests/typecheck/should_compile/T14451.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# Language KindSignatures, TypeOperators, PolyKinds, TypeOperators, ConstraintKinds, TypeFamilies, DataKinds, TypeInType, GADTs, AllowAmbiguousTypes, InstanceSigs, RankNTypes, UndecidableInstances #-} module T14451 where diff --git a/testsuite/tests/typecheck/should_compile/T14590.stderr b/testsuite/tests/typecheck/should_compile/T14590.stderr index 6f0ab068bcb6..4704a7aa01db 100644 --- a/testsuite/tests/typecheck/should_compile/T14590.stderr +++ b/testsuite/tests/typecheck/should_compile/T14590.stderr @@ -1,5 +1,5 @@ -T14590.hs:4:13: warning: [-Wtyped-holes (in -Wdefault)] +T14590.hs:4:11: warning: [-Wtyped-holes (in -Wdefault)] • Found hole: _ :: Int -> Int -> Int • In the expression: (x `_`) y In an equation for ‘f1’: f1 x y = (x `_`) y @@ -85,7 +85,7 @@ T14590.hs:4:13: warning: [-Wtyped-holes (in -Wdefault)] (imported from ‘Prelude’ at T14590.hs:1:8-13 (and originally defined in ‘GHC.Base’)) -T14590.hs:5:13: warning: [-Wtyped-holes (in -Wdefault)] +T14590.hs:5:11: warning: [-Wtyped-holes (in -Wdefault)] • Found hole: _a :: Int -> Int -> Int Or perhaps ‘_a’ is mis-spelled, or not in scope • In the expression: (x `_a`) y diff --git a/testsuite/tests/typecheck/should_compile/T14735.hs b/testsuite/tests/typecheck/should_compile/T14735.hs index c48231b7c2b0..0a00379b6b5d 100644 --- a/testsuite/tests/typecheck/should_compile/T14735.hs +++ b/testsuite/tests/typecheck/should_compile/T14735.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# Language QuantifiedConstraints #-} {-# Language StandaloneDeriving #-} {-# Language DataKinds #-} diff --git a/testsuite/tests/typecheck/should_compile/T14763.hs b/testsuite/tests/typecheck/should_compile/T14763.hs index c159291322fa..8bb451c7fe35 100644 --- a/testsuite/tests/typecheck/should_compile/T14763.hs +++ b/testsuite/tests/typecheck/should_compile/T14763.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE FunctionalDependencies #-} {-# LANGUAGE GADTs #-} {-# LANGUAGE KindSignatures #-} diff --git a/testsuite/tests/typecheck/should_compile/T15079.hs b/testsuite/tests/typecheck/should_compile/T15079.hs index 62115182afda..22e86abc5608 100644 --- a/testsuite/tests/typecheck/should_compile/T15079.hs +++ b/testsuite/tests/typecheck/should_compile/T15079.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE DataKinds #-} {-# LANGUAGE GADTs #-} {-# LANGUAGE PolyKinds #-} diff --git a/testsuite/tests/typecheck/should_compile/T17202.hs b/testsuite/tests/typecheck/should_compile/T17202.hs index 9f28ccc75344..cda5783ec9f1 100644 --- a/testsuite/tests/typecheck/should_compile/T17202.hs +++ b/testsuite/tests/typecheck/should_compile/T17202.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE GADTs #-} {-# LANGUAGE QuantifiedConstraints #-} {-# LANGUAGE TypeFamilies #-} diff --git a/testsuite/tests/typecheck/should_compile/T17562b.hs b/testsuite/tests/typecheck/should_compile/T17562b.hs index 0d635d9248c6..b73e6b1bc7b0 100644 --- a/testsuite/tests/typecheck/should_compile/T17562b.hs +++ b/testsuite/tests/typecheck/should_compile/T17562b.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE QuantifiedConstraints, MultiParamTypeClasses, TypeFamilies #-} -- NB: No PolyKinds diff --git a/testsuite/tests/typecheck/should_compile/T17567StupidThetaB.hs b/testsuite/tests/typecheck/should_compile/T17567StupidThetaB.hs index 36a4bca1e53c..d5555110043c 100644 --- a/testsuite/tests/typecheck/should_compile/T17567StupidThetaB.hs +++ b/testsuite/tests/typecheck/should_compile/T17567StupidThetaB.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE QuantifiedConstraints, DatatypeContexts, TypeFamilies #-} -- NB: -XNoPolyKinds, to get defaulting. diff --git a/testsuite/tests/typecheck/should_compile/T17567StupidThetaB.stderr b/testsuite/tests/typecheck/should_compile/T17567StupidThetaB.stderr index 5e98268d8b0e..3975d2c54dd6 100644 --- a/testsuite/tests/typecheck/should_compile/T17567StupidThetaB.stderr +++ b/testsuite/tests/typecheck/should_compile/T17567StupidThetaB.stderr @@ -1,3 +1,3 @@ -T17567StupidThetaB.hs:1:37: warning: +T17567StupidThetaB.hs:2:37: warning: -XDatatypeContexts is deprecated: It was widely considered a misfeature, and has been removed from the Haskell language. diff --git a/testsuite/tests/typecheck/should_compile/T4355.hs b/testsuite/tests/typecheck/should_compile/T4355.hs index 7e49dd822531..62ba16baa006 100644 --- a/testsuite/tests/typecheck/should_compile/T4355.hs +++ b/testsuite/tests/typecheck/should_compile/T4355.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# OPTIONS_GHC -fno-warn-redundant-constraints -fno-warn-missing-methods #-} {-# LANGUAGE DeriveDataTypeable, ExistentialQuantification, RankNTypes, MultiParamTypeClasses, FunctionalDependencies, FlexibleInstances, FlexibleContexts, PatternGuards, DatatypeContexts #-} diff --git a/testsuite/tests/typecheck/should_compile/T4355.stderr b/testsuite/tests/typecheck/should_compile/T4355.stderr index a977ce019096..77d919f9920d 100644 --- a/testsuite/tests/typecheck/should_compile/T4355.stderr +++ b/testsuite/tests/typecheck/should_compile/T4355.stderr @@ -1,3 +1,3 @@ -T4355.hs:2:172: Warning: +T4355.hs:3:172: warning: -XDatatypeContexts is deprecated: It was widely considered a misfeature, and has been removed from the Haskell language. diff --git a/testsuite/tests/typecheck/should_compile/T4524.hs b/testsuite/tests/typecheck/should_compile/T4524.hs index fbdc0cd77cc9..9f86ecd00c93 100644 --- a/testsuite/tests/typecheck/should_compile/T4524.hs +++ b/testsuite/tests/typecheck/should_compile/T4524.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# OPTIONS_GHC -fno-warn-redundant-constraints #-} {-# LANGUAGE GADTs, diff --git a/testsuite/tests/typecheck/should_compile/T5490.hs b/testsuite/tests/typecheck/should_compile/T5490.hs index 5679ee9baaf5..487fe0d84194 100644 --- a/testsuite/tests/typecheck/should_compile/T5490.hs +++ b/testsuite/tests/typecheck/should_compile/T5490.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE UnicodeSyntax #-} {-# LANGUAGE DeriveDataTypeable #-} {-# LANGUAGE ViewPatterns #-} diff --git a/testsuite/tests/typecheck/should_compile/T5490.stderr b/testsuite/tests/typecheck/should_compile/T5490.stderr index 93ae57550f2a..bd54d9df941d 100644 --- a/testsuite/tests/typecheck/should_compile/T5490.stderr +++ b/testsuite/tests/typecheck/should_compile/T5490.stderr @@ -1,4 +1,4 @@ -T5490.hs:295:5: warning: [-Woverlapping-patterns (in -Wdefault)] +T5490.hs:296:5: warning: [-Woverlapping-patterns (in -Wdefault)] Pattern match is redundant In a case alternative: _ -> ... diff --git a/testsuite/tests/typecheck/should_compile/T6018.hs b/testsuite/tests/typecheck/should_compile/T6018.hs index e8a194343b52..f4b431cda48c 100644 --- a/testsuite/tests/typecheck/should_compile/T6018.hs +++ b/testsuite/tests/typecheck/should_compile/T6018.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE DataKinds #-} {-# LANGUAGE MultiParamTypeClasses #-} {-# LANGUAGE PolyKinds #-} diff --git a/testsuite/tests/typecheck/should_compile/T6018.stderr b/testsuite/tests/typecheck/should_compile/T6018.stderr index c4baec422de0..9423a0e70632 100644 --- a/testsuite/tests/typecheck/should_compile/T6018.stderr +++ b/testsuite/tests/typecheck/should_compile/T6018.stderr @@ -2,10 +2,10 @@ [2 of 3] Compiling T6018a ( T6018a.hs, T6018a.o ) [3 of 3] Compiling T6018 ( T6018.hs, T6018.o ) -T6018.hs:108:5: warning: +T6018.hs:109:5: warning: Type family instance equation is overlapped: - Foo Bool = Bool -- Defined at T6018.hs:108:5 + Foo Bool = Bool -- Defined at T6018.hs:109:5 -T6018.hs:115:5: warning: +T6018.hs:116:5: warning: Type family instance equation is overlapped: - Bar Bool = Char -- Defined at T6018.hs:115:5 + Bar Bool = Char -- Defined at T6018.hs:116:5 diff --git a/testsuite/tests/typecheck/should_compile/T7503a.hs b/testsuite/tests/typecheck/should_compile/T7503a.hs index 61c0fb34e270..638265a8dfb3 100644 --- a/testsuite/tests/typecheck/should_compile/T7503a.hs +++ b/testsuite/tests/typecheck/should_compile/T7503a.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE ExistentialQuantification, DataKinds, PolyKinds, KindSignatures, GADTs #-} module T7503a where import Data.Kind diff --git a/testsuite/tests/typecheck/should_compile/T9151.hs b/testsuite/tests/typecheck/should_compile/T9151.hs index 351c563b6738..c3546438d2ec 100644 --- a/testsuite/tests/typecheck/should_compile/T9151.hs +++ b/testsuite/tests/typecheck/should_compile/T9151.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE PolyKinds, DataKinds, TypeFamilies, UndecidableInstances #-} module T9151 where diff --git a/testsuite/tests/typecheck/should_compile/Tc251_Help.hs b/testsuite/tests/typecheck/should_compile/Tc251_Help.hs index c4d29d45bc1b..57d86f83eb1f 100644 --- a/testsuite/tests/typecheck/should_compile/Tc251_Help.hs +++ b/testsuite/tests/typecheck/should_compile/Tc251_Help.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies #-} module Tc251_Help where diff --git a/testsuite/tests/typecheck/should_compile/Tc271.hs b/testsuite/tests/typecheck/should_compile/Tc271.hs index 5f0c3f0a1a9a..25971223f764 100644 --- a/testsuite/tests/typecheck/should_compile/Tc271.hs +++ b/testsuite/tests/typecheck/should_compile/Tc271.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module Tc271 where import Tc271a diff --git a/testsuite/tests/typecheck/should_compile/Tc271.hs-boot b/testsuite/tests/typecheck/should_compile/Tc271.hs-boot index 9f15065a11e6..0e264a93f5d0 100644 --- a/testsuite/tests/typecheck/should_compile/Tc271.hs-boot +++ b/testsuite/tests/typecheck/should_compile/Tc271.hs-boot @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module Tc271 where class K a where diff --git a/testsuite/tests/typecheck/should_compile/Tc271a.hs b/testsuite/tests/typecheck/should_compile/Tc271a.hs index b5fd136599e0..526b5482ee28 100644 --- a/testsuite/tests/typecheck/should_compile/Tc271a.hs +++ b/testsuite/tests/typecheck/should_compile/Tc271a.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module Tc271a where import {-# SOURCE #-} Tc271 diff --git a/testsuite/tests/typecheck/should_compile/tc146.hs b/testsuite/tests/typecheck/should_compile/tc146.hs index 5603c5ed78ee..61fac49197fc 100644 --- a/testsuite/tests/typecheck/should_compile/tc146.hs +++ b/testsuite/tests/typecheck/should_compile/tc146.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE RankNTypes #-} -- The interesting thing about this one is that diff --git a/testsuite/tests/typecheck/should_compile/tc153.hs b/testsuite/tests/typecheck/should_compile/tc153.hs index a127cdcb8bce..b255ac25c086 100644 --- a/testsuite/tests/typecheck/should_compile/tc153.hs +++ b/testsuite/tests/typecheck/should_compile/tc153.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} -- No ScopedTypeVariables, so (v::a) means (v:: forall a.a) module ShouldCompile where diff --git a/testsuite/tests/typecheck/should_compile/tc231.hs b/testsuite/tests/typecheck/should_compile/tc231.hs index a00f17cf83da..9e91be3a6abf 100644 --- a/testsuite/tests/typecheck/should_compile/tc231.hs +++ b/testsuite/tests/typecheck/should_compile/tc231.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# OPTIONS_GHC -ddump-types -dsuppress-module-prefixes #-} {-# LANGUAGE MultiParamTypeClasses, FunctionalDependencies, FlexibleContexts #-} diff --git a/testsuite/tests/typecheck/should_compile/tc250.hs b/testsuite/tests/typecheck/should_compile/tc250.hs index 5d6e8beeb991..445d702b69d7 100644 --- a/testsuite/tests/typecheck/should_compile/tc250.hs +++ b/testsuite/tests/typecheck/should_compile/tc250.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies #-} module ShouldCompile where diff --git a/testsuite/tests/typecheck/should_compile/tc251.hs b/testsuite/tests/typecheck/should_compile/tc251.hs index bf9ef3478790..e9315263af17 100644 --- a/testsuite/tests/typecheck/should_compile/tc251.hs +++ b/testsuite/tests/typecheck/should_compile/tc251.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies #-} module ShouldCompile where diff --git a/testsuite/tests/typecheck/should_compile/tc252.hs b/testsuite/tests/typecheck/should_compile/tc252.hs index 215e1ff8cc01..1ad9c7c5143c 100644 --- a/testsuite/tests/typecheck/should_compile/tc252.hs +++ b/testsuite/tests/typecheck/should_compile/tc252.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies #-} module ShouldCompile where diff --git a/testsuite/tests/typecheck/should_compile/tc253.hs b/testsuite/tests/typecheck/should_compile/tc253.hs index 7a337ed63956..7553b756a8aa 100644 --- a/testsuite/tests/typecheck/should_compile/tc253.hs +++ b/testsuite/tests/typecheck/should_compile/tc253.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies #-} {-# LANGUAGE UndecidableInstances #-} -- this is needed because |FamHelper a x| /< |Fam a x| diff --git a/testsuite/tests/typecheck/should_fail/AssocTyDef02.hs b/testsuite/tests/typecheck/should_fail/AssocTyDef02.hs index 5db82037bac9..c8e5966435ba 100644 --- a/testsuite/tests/typecheck/should_fail/AssocTyDef02.hs +++ b/testsuite/tests/typecheck/should_fail/AssocTyDef02.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies #-} module AssocTyDef02 where diff --git a/testsuite/tests/typecheck/should_fail/AssocTyDef02.stderr b/testsuite/tests/typecheck/should_fail/AssocTyDef02.stderr index 79c3e86c6771..b48667632337 100644 --- a/testsuite/tests/typecheck/should_fail/AssocTyDef02.stderr +++ b/testsuite/tests/typecheck/should_fail/AssocTyDef02.stderr @@ -1,5 +1,5 @@ -AssocTyDef02.hs:6:5: error: +AssocTyDef02.hs:7:5: error: • Illegal argument ‘[b]’ in: ‘type Typ [b] = ...’ The arguments to ‘Typ’ must all be distinct type variables diff --git a/testsuite/tests/typecheck/should_fail/LevPolyBounded.hs b/testsuite/tests/typecheck/should_fail/LevPolyBounded.hs index 0a68a69a38a5..674de050d630 100644 --- a/testsuite/tests/typecheck/should_fail/LevPolyBounded.hs +++ b/testsuite/tests/typecheck/should_fail/LevPolyBounded.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} -- inspired by comment:25 on #12708 {-# LANGUAGE PolyKinds #-} diff --git a/testsuite/tests/typecheck/should_fail/LevPolyBounded.stderr b/testsuite/tests/typecheck/should_fail/LevPolyBounded.stderr index c4c8d83a774d..d5c20ed70faa 100644 --- a/testsuite/tests/typecheck/should_fail/LevPolyBounded.stderr +++ b/testsuite/tests/typecheck/should_fail/LevPolyBounded.stderr @@ -1,16 +1,16 @@ -LevPolyBounded.hs:10:15: error: +LevPolyBounded.hs:11:15: error: • Expected a type, but ‘a’ has kind ‘TYPE r’ ‘r’ is a rigid type variable bound by the class declaration for ‘XBounded’ - at LevPolyBounded.hs:9:17-27 + at LevPolyBounded.hs:10:17-27 • In the type signature: LevPolyBounded.minBound :: a In the class declaration for ‘XBounded’ -LevPolyBounded.hs:11:15: error: +LevPolyBounded.hs:12:15: error: • Expected a type, but ‘a’ has kind ‘TYPE r’ ‘r’ is a rigid type variable bound by the class declaration for ‘XBounded’ - at LevPolyBounded.hs:9:17-27 + at LevPolyBounded.hs:10:17-27 • In the type signature: LevPolyBounded.maxBound :: a In the class declaration for ‘XBounded’ diff --git a/testsuite/tests/typecheck/should_fail/T10351.hs b/testsuite/tests/typecheck/should_fail/T10351.hs index 411698b397bb..6be96a230148 100644 --- a/testsuite/tests/typecheck/should_fail/T10351.hs +++ b/testsuite/tests/typecheck/should_fail/T10351.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module T10351 where class C a where diff --git a/testsuite/tests/typecheck/should_fail/T10351.stderr b/testsuite/tests/typecheck/should_fail/T10351.stderr index bd28a5a3e113..22acdf50dbea 100644 --- a/testsuite/tests/typecheck/should_fail/T10351.stderr +++ b/testsuite/tests/typecheck/should_fail/T10351.stderr @@ -1,5 +1,5 @@ -T10351.hs:6:1: error: +T10351.hs:7:1: error: • Non type-variable argument in the constraint: C [a] (Use FlexibleContexts to permit this) • When checking the inferred type diff --git a/testsuite/tests/typecheck/should_fail/T11563.hs b/testsuite/tests/typecheck/should_fail/T11563.hs index 83992da92b60..5a04c84cf6b4 100644 --- a/testsuite/tests/typecheck/should_fail/T11563.hs +++ b/testsuite/tests/typecheck/should_fail/T11563.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module T11563 where data T a = MkT diff --git a/testsuite/tests/typecheck/should_fail/T11563.stderr b/testsuite/tests/typecheck/should_fail/T11563.stderr index 27eca8481647..5ed6d3c7997b 100644 --- a/testsuite/tests/typecheck/should_fail/T11563.stderr +++ b/testsuite/tests/typecheck/should_fail/T11563.stderr @@ -1,5 +1,5 @@ -T11563.hs:5:19: error: +T11563.hs:6:19: error: • Expecting one more argument to ‘T’ Expected a type, but ‘T’ has kind ‘* -> *’ • In the first argument of ‘C’, namely ‘T’ diff --git a/testsuite/tests/typecheck/should_fail/T12083a.hs b/testsuite/tests/typecheck/should_fail/T12083a.hs index 0ca86f722252..9d5021387d90 100644 --- a/testsuite/tests/typecheck/should_fail/T12083a.hs +++ b/testsuite/tests/typecheck/should_fail/T12083a.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies #-} {-# LANGUAGE UnicodeSyntax #-} module T12803a where diff --git a/testsuite/tests/typecheck/should_fail/T12083a.stderr b/testsuite/tests/typecheck/should_fail/T12083a.stderr index fe126f9f0b91..05f1450008af 100644 --- a/testsuite/tests/typecheck/should_fail/T12083a.stderr +++ b/testsuite/tests/typecheck/should_fail/T12083a.stderr @@ -1,10 +1,10 @@ -T12083a.hs:5:1: error: +T12083a.hs:6:1: error: • Illegal qualified type: Num a => a Perhaps you intended to use RankNTypes • In the type synonym declaration for ‘Constrd’ -T12083a.hs:9:26: error: +T12083a.hs:10:26: error: • Data constructor ‘ExistentiallyLost’ has existential type variables, a context, or a specialised result type ExistentiallyLost :: forall u. TC u => u -> ExistentiallyLost (Enable ExistentialQuantification or GADTs to allow this) diff --git a/testsuite/tests/typecheck/should_fail/T12083b.hs b/testsuite/tests/typecheck/should_fail/T12083b.hs index 3992db3f9e3d..54985df32f7e 100644 --- a/testsuite/tests/typecheck/should_fail/T12083b.hs +++ b/testsuite/tests/typecheck/should_fail/T12083b.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE GADTs #-} module T12083b where diff --git a/testsuite/tests/typecheck/should_fail/T12083b.stderr b/testsuite/tests/typecheck/should_fail/T12083b.stderr index 87649ec4c35e..98ff9bb6a04b 100644 --- a/testsuite/tests/typecheck/should_fail/T12083b.stderr +++ b/testsuite/tests/typecheck/should_fail/T12083b.stderr @@ -1,5 +1,5 @@ -T12083b.hs:6:5: error: +T12083b.hs:7:5: error: • Illegal qualified type: Eq a => r Perhaps you intended to use RankNTypes • When checking the class method: diff --git a/testsuite/tests/typecheck/should_fail/T12430.hs b/testsuite/tests/typecheck/should_fail/T12430.hs index 03cded2b44ce..b5144604db1a 100644 --- a/testsuite/tests/typecheck/should_fail/T12430.hs +++ b/testsuite/tests/typecheck/should_fail/T12430.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilyDependencies #-} module T12430 where diff --git a/testsuite/tests/typecheck/should_fail/T12430.stderr b/testsuite/tests/typecheck/should_fail/T12430.stderr index fd73b40fc4c6..eab71af1fc2a 100644 --- a/testsuite/tests/typecheck/should_fail/T12430.stderr +++ b/testsuite/tests/typecheck/should_fail/T12430.stderr @@ -1,8 +1,8 @@ -T12430.hs:6:3: error: +T12430.hs:7:3: error: • Type family equation violates the family's injectivity annotation. Type variable ‘x’ cannot be inferred from the right-hand side. In the type family equation: - F x = C x -- Defined at T12430.hs:6:3 + F x = C x -- Defined at T12430.hs:7:3 • In the equations for closed type family ‘F’ In the type family declaration for ‘F’ diff --git a/testsuite/tests/typecheck/should_fail/T12563.hs b/testsuite/tests/typecheck/should_fail/T12563.hs index 394fa615d8c4..745f0b77dda3 100644 --- a/testsuite/tests/typecheck/should_fail/T12563.hs +++ b/testsuite/tests/typecheck/should_fail/T12563.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE RankNTypes #-} module T12563 where diff --git a/testsuite/tests/typecheck/should_fail/T12563.stderr b/testsuite/tests/typecheck/should_fail/T12563.stderr index f141a23e9634..c5b8e1dc40c6 100644 --- a/testsuite/tests/typecheck/should_fail/T12563.stderr +++ b/testsuite/tests/typecheck/should_fail/T12563.stderr @@ -1,5 +1,5 @@ -T12563.hs:7:15: error: +T12563.hs:8:15: error: • Couldn't match expected type ‘(forall a. f0 a) -> f0 r0’ with actual type ‘p0’ Cannot instantiate unification variable ‘p0’ @@ -8,5 +8,5 @@ T12563.hs:7:15: error: In the expression: foo g In the expression: \ g -> foo g • Relevant bindings include - g :: p0 (bound at T12563.hs:7:6) - x :: p0 -> f0 r0 (bound at T12563.hs:7:1) + g :: p0 (bound at T12563.hs:8:6) + x :: p0 -> f0 r0 (bound at T12563.hs:8:1) diff --git a/testsuite/tests/typecheck/should_fail/T12785b.hs b/testsuite/tests/typecheck/should_fail/T12785b.hs index 951b04c6cd5f..ccc53f609345 100644 --- a/testsuite/tests/typecheck/should_fail/T12785b.hs +++ b/testsuite/tests/typecheck/should_fail/T12785b.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE RankNTypes, TypeOperators, ViewPatterns #-} {-# LANGUAGE TypeFamilies #-} {-# LANGUAGE DataKinds, PolyKinds, GADTs #-} diff --git a/testsuite/tests/typecheck/should_fail/T12785b.stderr b/testsuite/tests/typecheck/should_fail/T12785b.stderr index 85d7361421d8..14ce110c0d74 100644 --- a/testsuite/tests/typecheck/should_fail/T12785b.stderr +++ b/testsuite/tests/typecheck/should_fail/T12785b.stderr @@ -1,5 +1,5 @@ -T12785b.hs:29:65: error: +T12785b.hs:30:65: error: • Could not deduce: Payload ('S n) (Payload n s1) ~ s arising from a use of ‘SBranchX’ from the context: m ~ 'S n @@ -7,13 +7,13 @@ T12785b.hs:29:65: error: Branch :: forall a (n :: Peano). a -> HTree n (HTree ('S n) a) -> HTree ('S n) a, in an equation for ‘nest’ - at T12785b.hs:29:7-51 + at T12785b.hs:30:7-51 ‘s’ is a rigid type variable bound by a pattern with constructor: Hide :: forall {a} (n :: Peano) (f :: a -> *) (s :: HTree n a). STree n f s -> Hidden n f, in an equation for ‘nest’ - at T12785b.hs:29:7-12 + at T12785b.hs:30:7-12 • In the second argument of ‘($)’, namely ‘a `SBranchX` tr’ In the expression: Hide $ a `SBranchX` tr In an equation for ‘nest’: @@ -21,7 +21,7 @@ T12785b.hs:29:65: error: = Hide $ a `SBranchX` tr • Relevant bindings include tr :: STree n (STree ('S n) (STree ('S ('S n)) f)) s1 - (bound at T12785b.hs:29:49) - a :: STree ('S m) f s (bound at T12785b.hs:29:12) + (bound at T12785b.hs:30:49) + a :: STree ('S m) f s (bound at T12785b.hs:30:12) nest :: HTree m (Hidden ('S m) f) -> Hidden m (STree ('S m) f) - (bound at T12785b.hs:27:1) + (bound at T12785b.hs:28:1) diff --git a/testsuite/tests/typecheck/should_fail/T14618.hs b/testsuite/tests/typecheck/should_fail/T14618.hs index da30d7ad8559..e032b7b27cdb 100644 --- a/testsuite/tests/typecheck/should_fail/T14618.hs +++ b/testsuite/tests/typecheck/should_fail/T14618.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE RankNTypes #-} module T14618 where diff --git a/testsuite/tests/typecheck/should_fail/T14618.stderr b/testsuite/tests/typecheck/should_fail/T14618.stderr index 2faf4a925bfc..c6fae3f81e12 100644 --- a/testsuite/tests/typecheck/should_fail/T14618.stderr +++ b/testsuite/tests/typecheck/should_fail/T14618.stderr @@ -1,12 +1,12 @@ -T14618.hs:6:14: error: +T14618.hs:7:14: error: • Couldn't match type ‘b’ with ‘forall c. a’ Expected: a -> b Actual: a -> forall c. a ‘b’ is a rigid type variable bound by the type signature for: safeCoerce :: forall a b. a -> b - at T14618.hs:5:1-20 + at T14618.hs:6:1-20 • In the expression: f' In an equation for ‘safeCoerce’: safeCoerce @@ -16,4 +16,4 @@ T14618.hs:6:14: error: f x = x f' = f • Relevant bindings include - safeCoerce :: a -> b (bound at T14618.hs:6:1) + safeCoerce :: a -> b (bound at T14618.hs:7:1) diff --git a/testsuite/tests/typecheck/should_fail/T14904a.hs b/testsuite/tests/typecheck/should_fail/T14904a.hs index af4cf65a333e..0043067e51dd 100644 --- a/testsuite/tests/typecheck/should_fail/T14904a.hs +++ b/testsuite/tests/typecheck/should_fail/T14904a.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE RankNTypes #-} {-# LANGUAGE TypeFamilies #-} {-# LANGUAGE PolyKinds #-} diff --git a/testsuite/tests/typecheck/should_fail/T14904a.stderr b/testsuite/tests/typecheck/should_fail/T14904a.stderr index 3b8d005bab4e..1ed0946f6c91 100644 --- a/testsuite/tests/typecheck/should_fail/T14904a.stderr +++ b/testsuite/tests/typecheck/should_fail/T14904a.stderr @@ -1,8 +1,8 @@ -T14904a.hs:9:6: error: +T14904a.hs:10:6: error: • Expected kind ‘forall (a :: k). g a’, but ‘f’ has kind ‘k1’ ‘k1’ is a rigid type variable bound by a family instance declaration - at T14904a.hs:9:3-30 + at T14904a.hs:10:3-30 • In the first argument of ‘F’, namely ‘(f :: forall a. g a)’ In the type family declaration for ‘F’ diff --git a/testsuite/tests/typecheck/should_fail/T15527.hs b/testsuite/tests/typecheck/should_fail/T15527.hs index b65c26ca7af8..ad5271359a7f 100644 --- a/testsuite/tests/typecheck/should_fail/T15527.hs +++ b/testsuite/tests/typecheck/should_fail/T15527.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module T15527 where f :: (Int -> Int) -> (Int -> Int) -> (Int -> Int) diff --git a/testsuite/tests/typecheck/should_fail/T15527.stderr b/testsuite/tests/typecheck/should_fail/T15527.stderr index 8908b172188f..6729c26bd58e 100644 --- a/testsuite/tests/typecheck/should_fail/T15527.stderr +++ b/testsuite/tests/typecheck/should_fail/T15527.stderr @@ -1,4 +1,4 @@ -T15527.hs:4:6: error: +T15527.hs:5:6: error: Illegal visible type application ‘@Int’ Perhaps you intended to use TypeApplications diff --git a/testsuite/tests/typecheck/should_fail/T15552a.hs b/testsuite/tests/typecheck/should_fail/T15552a.hs index 86c71dc9c011..67fa4dd74105 100644 --- a/testsuite/tests/typecheck/should_fail/T15552a.hs +++ b/testsuite/tests/typecheck/should_fail/T15552a.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE DataKinds, ExistentialQuantification, GADTs, PolyKinds, TypeOperators #-} {-# LANGUAGE TypeInType, TypeFamilies #-} {- # LANGUAGE UndecidableInstances #-} diff --git a/testsuite/tests/typecheck/should_fail/T15552a.stderr b/testsuite/tests/typecheck/should_fail/T15552a.stderr index 9f44248ae21a..f7a6094d9ec4 100644 --- a/testsuite/tests/typecheck/should_fail/T15552a.stderr +++ b/testsuite/tests/typecheck/should_fail/T15552a.stderr @@ -1,22 +1,21 @@ -T15552a.hs:25:9: error: +T15552a.hs:26:9: error: • Illegal nested type family application ‘GetEntryOfVal (FirstEntryOfVal v kvs)’ (Use UndecidableInstances to permit this) • In the equations for closed type family ‘FirstEntryOfVal’ In the type family declaration for ‘FirstEntryOfVal’ -T15552a.hs:25:9: error: +T15552a.hs:26:9: error: • Illegal nested type family application ‘EntryOfValKey (FirstEntryOfVal v kvs)’ (Use UndecidableInstances to permit this) • In the equations for closed type family ‘FirstEntryOfVal’ In the type family declaration for ‘FirstEntryOfVal’ -T15552a.hs:25:9: error: +T15552a.hs:26:9: error: • Illegal nested type family application ‘EntryOfValKey (FirstEntryOfVal v kvs)’ (Use UndecidableInstances to permit this) • In the equations for closed type family ‘FirstEntryOfVal’ In the type family declaration for ‘FirstEntryOfVal’ - diff --git a/testsuite/tests/typecheck/should_fail/T15712.hs b/testsuite/tests/typecheck/should_fail/T15712.hs index a0b1d5f975c9..855e96a8f578 100644 --- a/testsuite/tests/typecheck/should_fail/T15712.hs +++ b/testsuite/tests/typecheck/should_fail/T15712.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# Language RankNTypes #-} {-# Language DerivingVia #-} {-# Language DeriveFunctor #-} diff --git a/testsuite/tests/typecheck/should_fail/T15712.stderr b/testsuite/tests/typecheck/should_fail/T15712.stderr index e8b5d397de4d..8031f5f0da98 100644 --- a/testsuite/tests/typecheck/should_fail/T15712.stderr +++ b/testsuite/tests/typecheck/should_fail/T15712.stderr @@ -1,5 +1,5 @@ -T15712.hs:18:16: error: +T15712.hs:19:16: error: • Expecting one more argument to ‘GEndo’ Expected kind ‘* -> *’, but ‘GEndo’ has kind ‘(* -> *) -> * -> *’ • In the first argument of ‘Codensity’, namely ‘GEndo’ diff --git a/testsuite/tests/typecheck/should_fail/T16059c.hs b/testsuite/tests/typecheck/should_fail/T16059c.hs index d26c7db6d4c6..6e705113e9a7 100644 --- a/testsuite/tests/typecheck/should_fail/T16059c.hs +++ b/testsuite/tests/typecheck/should_fail/T16059c.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module T16059c where import T16059b diff --git a/testsuite/tests/typecheck/should_fail/T16059c.stderr b/testsuite/tests/typecheck/should_fail/T16059c.stderr index 6c6113fb5f63..873b7088bf33 100644 --- a/testsuite/tests/typecheck/should_fail/T16059c.stderr +++ b/testsuite/tests/typecheck/should_fail/T16059c.stderr @@ -1,5 +1,5 @@ -T16059c.hs:5:6: error: +T16059c.hs:6:6: error: • Illegal polymorphic type: forall a1. a1 Perhaps you intended to use RankNTypes • In the expansion of type synonym ‘Foo’ diff --git a/testsuite/tests/typecheck/should_fail/T16059e.hs b/testsuite/tests/typecheck/should_fail/T16059e.hs index 4747edc30234..ba4bff5f8c0b 100644 --- a/testsuite/tests/typecheck/should_fail/T16059e.hs +++ b/testsuite/tests/typecheck/should_fail/T16059e.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module T16059e where import T16059b diff --git a/testsuite/tests/typecheck/should_fail/T16059e.stderr b/testsuite/tests/typecheck/should_fail/T16059e.stderr index f5a6bb00baa7..582d5fbe62f3 100644 --- a/testsuite/tests/typecheck/should_fail/T16059e.stderr +++ b/testsuite/tests/typecheck/should_fail/T16059e.stderr @@ -1,5 +1,5 @@ -T16059e.hs:14:6: error: +T16059e.hs:15:6: error: • Illegal polymorphic type: forall a. a Perhaps you intended to use RankNTypes • In the expansion of type synonym ‘Foo’ diff --git a/testsuite/tests/typecheck/should_fail/T16255.hs b/testsuite/tests/typecheck/should_fail/T16255.hs index ef2f0a9cb6ff..2f20d4c788c6 100644 --- a/testsuite/tests/typecheck/should_fail/T16255.hs +++ b/testsuite/tests/typecheck/should_fail/T16255.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE DataKinds #-} {-# LANGUAGE PolyKinds #-} {-# LANGUAGE RankNTypes #-} diff --git a/testsuite/tests/typecheck/should_fail/T16255.stderr b/testsuite/tests/typecheck/should_fail/T16255.stderr index 74379a316cb7..ba23f0e466c3 100644 --- a/testsuite/tests/typecheck/should_fail/T16255.stderr +++ b/testsuite/tests/typecheck/should_fail/T16255.stderr @@ -1,10 +1,10 @@ -T16255.hs:13:3: error: +T16255.hs:14:3: error: • Illegal oversaturated visible kind argument: ‘@Bool’ • In the equations for closed type family ‘F1’ In the type family declaration for ‘F1’ -T16255.hs:21:3: error: +T16255.hs:22:3: error: • Illegal oversaturated visible kind argument: ‘@Symbol’ • In the equations for closed type family ‘F2’ In the type family declaration for ‘F2’ diff --git a/testsuite/tests/typecheck/should_fail/T16414.hs b/testsuite/tests/typecheck/should_fail/T16414.hs index 27807e82bfac..592aa7de3ce5 100644 --- a/testsuite/tests/typecheck/should_fail/T16414.hs +++ b/testsuite/tests/typecheck/should_fail/T16414.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE FlexibleContexts, FlexibleInstances, AllowAmbiguousTypes #-} {-# LANGUAGE UndecidableSuperClasses #-} module T16414 where diff --git a/testsuite/tests/typecheck/should_fail/T16414.stderr b/testsuite/tests/typecheck/should_fail/T16414.stderr index 5cfbf7549ad9..601f4097dbbc 100644 --- a/testsuite/tests/typecheck/should_fail/T16414.stderr +++ b/testsuite/tests/typecheck/should_fail/T16414.stderr @@ -1,13 +1,13 @@ -T16414.hs:14:6: error: +T16414.hs:15:6: error: • Overlapping instances for AllZip2 f0 arising from a use of ‘f2’ Matching givens (or their superclasses): AllZip2 I bound by the type signature for: f1 :: forall x. (All x, AllZip2 I) => x -> () - at T16414.hs:13:1-35 + at T16414.hs:14:1-35 Matching instances: - instance AllZip2 f -- Defined at T16414.hs:11:10 + instance AllZip2 f -- Defined at T16414.hs:12:10 (The choice depends on the instantiation of ‘f0’) • In the expression: f2 In an equation for ‘f1’: f1 = f2 diff --git a/testsuite/tests/typecheck/should_fail/T16502.hs b/testsuite/tests/typecheck/should_fail/T16502.hs index 5fac062d8572..c5ddea393873 100644 --- a/testsuite/tests/typecheck/should_fail/T16502.hs +++ b/testsuite/tests/typecheck/should_fail/T16502.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE FlexibleContexts #-} {-# LANGUAGE FlexibleInstances #-} {-# LANGUAGE MultiParamTypeClasses #-} diff --git a/testsuite/tests/typecheck/should_fail/T17213.hs b/testsuite/tests/typecheck/should_fail/T17213.hs index e9c093c903d1..8f35d459f510 100644 --- a/testsuite/tests/typecheck/should_fail/T17213.hs +++ b/testsuite/tests/typecheck/should_fail/T17213.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module T17213 where import T17213a diff --git a/testsuite/tests/typecheck/should_fail/T17213.stderr b/testsuite/tests/typecheck/should_fail/T17213.stderr index 117299266018..ff73505d26a7 100644 --- a/testsuite/tests/typecheck/should_fail/T17213.stderr +++ b/testsuite/tests/typecheck/should_fail/T17213.stderr @@ -1,5 +1,5 @@ -T17213.hs:5:1: error: +T17213.hs:6:1: error: • Illegal polymorphic type: forall a. a -> a Perhaps you intended to use RankNTypes • When checking the inferred type diff --git a/testsuite/tests/typecheck/should_fail/T17563.hs b/testsuite/tests/typecheck/should_fail/T17563.hs index cab972a1bf77..565cd9f59eac 100644 --- a/testsuite/tests/typecheck/should_fail/T17563.hs +++ b/testsuite/tests/typecheck/should_fail/T17563.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE QuantifiedConstraints #-} module T17563 where diff --git a/testsuite/tests/typecheck/should_fail/T17563.stderr b/testsuite/tests/typecheck/should_fail/T17563.stderr index c24587c1a69a..5b46701859f2 100644 --- a/testsuite/tests/typecheck/should_fail/T17563.stderr +++ b/testsuite/tests/typecheck/should_fail/T17563.stderr @@ -1,5 +1,5 @@ -T17563.hs:5:9: error: +T17563.hs:6:9: error: • Illegal equational constraint a b ~ a c (Use GADTs or TypeFamilies to permit this) • In the quantified constraint ‘forall (a :: * -> *). a b ~ a c’ diff --git a/testsuite/tests/typecheck/should_fail/T18939_Fail.hs b/testsuite/tests/typecheck/should_fail/T18939_Fail.hs index c2faade86595..04ceec1e2a92 100644 --- a/testsuite/tests/typecheck/should_fail/T18939_Fail.hs +++ b/testsuite/tests/typecheck/should_fail/T18939_Fail.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE ExplicitForAll #-} {-# LANGUAGE PolyKinds #-} module T18939_Fail where diff --git a/testsuite/tests/typecheck/should_fail/T18939_Fail.stderr b/testsuite/tests/typecheck/should_fail/T18939_Fail.stderr index 2cdbab4bb31a..eb9bb6c5fdbf 100644 --- a/testsuite/tests/typecheck/should_fail/T18939_Fail.stderr +++ b/testsuite/tests/typecheck/should_fail/T18939_Fail.stderr @@ -1,5 +1,5 @@ -T18939_Fail.hs:5:1: error: +T18939_Fail.hs:6:1: error: • Illegal polymorphic type: forall a -> a Perhaps you intended to use RankNTypes • In the data type declaration for ‘F’ diff --git a/testsuite/tests/typecheck/should_fail/T19109.hs b/testsuite/tests/typecheck/should_fail/T19109.hs index 614f883b5297..d1037260c821 100644 --- a/testsuite/tests/typecheck/should_fail/T19109.hs +++ b/testsuite/tests/typecheck/should_fail/T19109.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module T19109 where import Data.Functor.Identity diff --git a/testsuite/tests/typecheck/should_fail/T19109.stderr b/testsuite/tests/typecheck/should_fail/T19109.stderr index 25ce53583555..83f60680dab1 100644 --- a/testsuite/tests/typecheck/should_fail/T19109.stderr +++ b/testsuite/tests/typecheck/should_fail/T19109.stderr @@ -1,4 +1,4 @@ -T19109.hs:5:4: error: +T19109.hs:6:4: error: Illegal visible type application in a pattern: ‘@Int’ Both ScopedTypeVariables and TypeApplications are required to use this feature diff --git a/testsuite/tests/typecheck/should_fail/T19187.hs b/testsuite/tests/typecheck/should_fail/T19187.hs index 52f0e11c695d..8ced67e5f4a9 100644 --- a/testsuite/tests/typecheck/should_fail/T19187.hs +++ b/testsuite/tests/typecheck/should_fail/T19187.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE UndecidableInstances #-} module T19187 where diff --git a/testsuite/tests/typecheck/should_fail/T19187.stderr b/testsuite/tests/typecheck/should_fail/T19187.stderr index 637cd22c4db1..45cc96833a73 100644 --- a/testsuite/tests/typecheck/should_fail/T19187.stderr +++ b/testsuite/tests/typecheck/should_fail/T19187.stderr @@ -1,5 +1,5 @@ -T19187.hs:7:10: error: +T19187.hs:8:10: error: • Non type-variable argument in the constraint: Eq Int (Use FlexibleContexts to permit this) • In the instance declaration for ‘Eq T’ diff --git a/testsuite/tests/typecheck/should_fail/T2247.hs b/testsuite/tests/typecheck/should_fail/T2247.hs index 3779f2db7609..9fdd92c2588d 100644 --- a/testsuite/tests/typecheck/should_fail/T2247.hs +++ b/testsuite/tests/typecheck/should_fail/T2247.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE FunctionalDependencies, MultiParamTypeClasses, UndecidableInstances, FlexibleInstances #-} module T2247 where diff --git a/testsuite/tests/typecheck/should_fail/T2247.stderr b/testsuite/tests/typecheck/should_fail/T2247.stderr index 54a6c2a23d15..8335fb003329 100644 --- a/testsuite/tests/typecheck/should_fail/T2247.stderr +++ b/testsuite/tests/typecheck/should_fail/T2247.stderr @@ -1,8 +1,8 @@ -T2247.hs:6:10: error: - Illegal instance declaration for ‘FD a b’ - The liberal coverage condition fails in class ‘FD’ - for functional dependency: ‘a -> b’ - Reason: lhs type ‘a’ does not determine rhs type ‘b’ - Un-determined variable: b - In the instance declaration for ‘FD a b’ +T2247.hs:7:10: error: + • Illegal instance declaration for ‘FD a b’ + The liberal coverage condition fails in class ‘FD’ + for functional dependency: ‘a -> b’ + Reason: lhs type ‘a’ does not determine rhs type ‘b’ + Un-determined variable: b + • In the instance declaration for ‘FD a b’ diff --git a/testsuite/tests/typecheck/should_fail/T2538.hs b/testsuite/tests/typecheck/should_fail/T2538.hs index 849256ad3a72..6f76293d7677 100644 --- a/testsuite/tests/typecheck/should_fail/T2538.hs +++ b/testsuite/tests/typecheck/should_fail/T2538.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} -- #2538 module ShouldFail where diff --git a/testsuite/tests/typecheck/should_fail/T2538.stderr b/testsuite/tests/typecheck/should_fail/T2538.stderr index 726ac8fd71b1..768ad65fa3b9 100644 --- a/testsuite/tests/typecheck/should_fail/T2538.stderr +++ b/testsuite/tests/typecheck/should_fail/T2538.stderr @@ -1,15 +1,15 @@ -T2538.hs:6:6: error: +T2538.hs:7:6: error: • Illegal qualified type: Eq a => a -> a Perhaps you intended to use RankNTypes • In the type signature: f :: (Eq a => a -> a) -> Int -T2538.hs:9:6: error: +T2538.hs:10:6: error: • Illegal qualified type: Eq a => a -> a Perhaps you intended to use ImpredicativeTypes • In the type signature: g :: [Eq a => a -> a] -> Int -T2538.hs:12:6: error: +T2538.hs:13:6: error: • Illegal qualified type: Eq a => a -> a Perhaps you intended to use ImpredicativeTypes • In the type signature: h :: Ix (Eq a => a -> a) => Int diff --git a/testsuite/tests/typecheck/should_fail/T2994.hs b/testsuite/tests/typecheck/should_fail/T2994.hs index aed2c4aa21a1..6a79e0ef9735 100644 --- a/testsuite/tests/typecheck/should_fail/T2994.hs +++ b/testsuite/tests/typecheck/should_fail/T2994.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE MultiParamTypeClasses #-} -- #2994 diff --git a/testsuite/tests/typecheck/should_fail/T2994.stderr b/testsuite/tests/typecheck/should_fail/T2994.stderr index 7f20acf5aa2e..a3ae3bc4d2c4 100644 --- a/testsuite/tests/typecheck/should_fail/T2994.stderr +++ b/testsuite/tests/typecheck/should_fail/T2994.stderr @@ -1,23 +1,23 @@ -T2994.hs:11:10: error: +T2994.hs:12:10: error: • Expecting one more argument to ‘MonadReader Int’ Expected a constraint, but ‘MonadReader Int’ has kind ‘* -> Constraint’ • In the instance declaration for ‘MonadReader Int’ -T2994.hs:13:10: error: +T2994.hs:14:10: error: • Expecting one more argument to ‘MonadReader (Reader' r)’ Expected a constraint, but ‘MonadReader (Reader' r)’ has kind ‘* -> Constraint’ • In the instance declaration for ‘MonadReader (Reader' r)’ -T2994.hs:13:23: error: +T2994.hs:14:23: error: • Expecting one more argument to ‘Reader' r’ Expected a type, but ‘Reader' r’ has kind ‘* -> *’ • In the first argument of ‘MonadReader’, namely ‘(Reader' r)’ In the instance declaration for ‘MonadReader (Reader' r)’ -T2994.hs:15:10: error: +T2994.hs:16:10: error: • Expected kind ‘(* -> *) -> Constraint’, but ‘MonadReader r r’ has kind ‘Constraint’ • In the instance declaration for ‘MonadReader r r (Reader' r)’ diff --git a/testsuite/tests/typecheck/should_fail/T3155.hs b/testsuite/tests/typecheck/should_fail/T3155.hs index 81f8c7d13964..129885f4383d 100644 --- a/testsuite/tests/typecheck/should_fail/T3155.hs +++ b/testsuite/tests/typecheck/should_fail/T3155.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE GADTs, TypeOperators #-} module T3155 where diff --git a/testsuite/tests/typecheck/should_fail/T3155.stderr b/testsuite/tests/typecheck/should_fail/T3155.stderr index 0f04d76bffea..e82803fd22d5 100644 --- a/testsuite/tests/typecheck/should_fail/T3155.stderr +++ b/testsuite/tests/typecheck/should_fail/T3155.stderr @@ -1,5 +1,5 @@ -T3155.hs:13:9: error: +T3155.hs:14:9: error: Illegal symbol ‘forall’ in type Perhaps you intended to use RankNTypes or a similar language extension to enable explicit-forall syntax: forall <tvs>. <type> diff --git a/testsuite/tests/typecheck/should_fail/T3468.hs b/testsuite/tests/typecheck/should_fail/T3468.hs index 4c4bf975bc21..f091f09b2c35 100644 --- a/testsuite/tests/typecheck/should_fail/T3468.hs +++ b/testsuite/tests/typecheck/should_fail/T3468.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE ExistentialQuantification #-} module T3468 where diff --git a/testsuite/tests/typecheck/should_fail/T3950.hs b/testsuite/tests/typecheck/should_fail/T3950.hs index 1a3bcc1d31a7..ca78ab68eaef 100644 --- a/testsuite/tests/typecheck/should_fail/T3950.hs +++ b/testsuite/tests/typecheck/should_fail/T3950.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE GADTs #-} module T3950 where diff --git a/testsuite/tests/typecheck/should_fail/T3950.stderr b/testsuite/tests/typecheck/should_fail/T3950.stderr index 69ff2764797b..16fde0e48869 100644 --- a/testsuite/tests/typecheck/should_fail/T3950.stderr +++ b/testsuite/tests/typecheck/should_fail/T3950.stderr @@ -1,5 +1,5 @@ -T3950.hs:15:13: error: +T3950.hs:16:13: error: • Couldn't match kind ‘*’ with ‘* -> *’ When matching types w :: (* -> * -> *) -> * @@ -15,4 +15,4 @@ T3950.hs:15:13: error: rp' :: Sealed (Id p x) rp' = undefined • Relevant bindings include - rp :: Bool -> Maybe (w (Id p)) (bound at T3950.hs:15:1) + rp :: Bool -> Maybe (w (Id p)) (bound at T3950.hs:16:1) diff --git a/testsuite/tests/typecheck/should_fail/T5300.hs b/testsuite/tests/typecheck/should_fail/T5300.hs index b15713d29019..e200ca0c24a5 100644 --- a/testsuite/tests/typecheck/should_fail/T5300.hs +++ b/testsuite/tests/typecheck/should_fail/T5300.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE FunctionalDependencies, MultiParamTypeClasses #-} module T5300 where diff --git a/testsuite/tests/typecheck/should_fail/T5300.stderr b/testsuite/tests/typecheck/should_fail/T5300.stderr index a80839455efd..06d870dff395 100644 --- a/testsuite/tests/typecheck/should_fail/T5300.stderr +++ b/testsuite/tests/typecheck/should_fail/T5300.stderr @@ -1,26 +1,26 @@ -T5300.hs:11:7: error: +T5300.hs:12:7: error: • Could not deduce (C1 a b c0) from the context: (Monad m, C1 a b c) bound by the type signature for: f1 :: forall (m :: * -> *) a b c. (Monad m, C1 a b c) => a -> StateT (T b) m a - at T5300.hs:11:7-50 + at T5300.hs:12:7-50 The type variable ‘c0’ is ambiguous • In the ambiguity check for ‘f1’ To defer the ambiguity check to use sites, enable AllowAmbiguousTypes In the type signature: f1 :: (Monad m, C1 a b c) => a -> StateT (T b) m a -T5300.hs:14:7: error: +T5300.hs:15:7: error: • Could not deduce (C1 a1 b1 c10) from the context: (Monad m, C1 a1 b1 c1, C2 a2 b2 c2) bound by the type signature for: f2 :: forall (m :: * -> *) a1 b1 c1 a2 b2 c2. (Monad m, C1 a1 b1 c1, C2 a2 b2 c2) => a1 -> StateT (T b2) m a2 - at T5300.hs:14:7-69 + at T5300.hs:15:7-69 The type variable ‘c10’ is ambiguous • In the ambiguity check for ‘f2’ To defer the ambiguity check to use sites, enable AllowAmbiguousTypes diff --git a/testsuite/tests/typecheck/should_fail/T5957.hs b/testsuite/tests/typecheck/should_fail/T5957.hs index c168a00f3a35..badb4309a1af 100644 --- a/testsuite/tests/typecheck/should_fail/T5957.hs +++ b/testsuite/tests/typecheck/should_fail/T5957.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module T5957 where flex :: Int -> Show a => a -> String diff --git a/testsuite/tests/typecheck/should_fail/T5957.stderr b/testsuite/tests/typecheck/should_fail/T5957.stderr index 66bc0c1d0d9e..05a7316915ca 100644 --- a/testsuite/tests/typecheck/should_fail/T5957.stderr +++ b/testsuite/tests/typecheck/should_fail/T5957.stderr @@ -1,6 +1,5 @@ -T5957.hs:3:9: error: +T5957.hs:4:9: error: • Illegal qualified type: Show a => a -> String Perhaps you intended to use RankNTypes - • In the type signature: - flex :: Int -> Show a => a -> String + • In the type signature: flex :: Int -> Show a => a -> String diff --git a/testsuite/tests/typecheck/should_fail/T6022.hs b/testsuite/tests/typecheck/should_fail/T6022.hs index 994b77962612..de4adb5ff90a 100644 --- a/testsuite/tests/typecheck/should_fail/T6022.hs +++ b/testsuite/tests/typecheck/should_fail/T6022.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module T6022 where f x = x == head diff --git a/testsuite/tests/typecheck/should_fail/T6022.stderr b/testsuite/tests/typecheck/should_fail/T6022.stderr index 6423925b12f2..9f4bc916228e 100644 --- a/testsuite/tests/typecheck/should_fail/T6022.stderr +++ b/testsuite/tests/typecheck/should_fail/T6022.stderr @@ -1,5 +1,5 @@ -T6022.hs:3:1: error: +T6022.hs:4:1: error: • Non type-variable argument in the constraint: Eq ([a] -> a) (Use FlexibleContexts to permit this) • When checking the inferred type diff --git a/testsuite/tests/typecheck/should_fail/T6069.stderr b/testsuite/tests/typecheck/should_fail/T6069.stderr index 98b0587bbc69..0456a842803f 100644 --- a/testsuite/tests/typecheck/should_fail/T6069.stderr +++ b/testsuite/tests/typecheck/should_fail/T6069.stderr @@ -23,5 +23,5 @@ T6069.hs:15:16: error: Expected: ST s2 Int -> b2 Actual: (forall s. ST s b2) -> b2 • In the second argument of ‘(.)’, namely ‘runST’ - In the first argument of ‘($)’, namely ‘(print . runST)’ + In the expression: print . runST In the expression: ((print . runST) $) fourty_two diff --git a/testsuite/tests/typecheck/should_fail/T8034.hs b/testsuite/tests/typecheck/should_fail/T8034.hs index e432152e08a8..c696f68e57e8 100644 --- a/testsuite/tests/typecheck/should_fail/T8034.hs +++ b/testsuite/tests/typecheck/should_fail/T8034.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies #-} module T8034 where diff --git a/testsuite/tests/typecheck/should_fail/T8034.stderr b/testsuite/tests/typecheck/should_fail/T8034.stderr index 8f645385546b..05f2ca42a3f4 100644 --- a/testsuite/tests/typecheck/should_fail/T8034.stderr +++ b/testsuite/tests/typecheck/should_fail/T8034.stderr @@ -1,5 +1,5 @@ -T8034.hs:6:3: error: +T8034.hs:7:3: error: • Couldn't match type: F a0 with: F a Expected: F a -> F a diff --git a/testsuite/tests/typecheck/should_fail/T8883.hs b/testsuite/tests/typecheck/should_fail/T8883.hs index c3af3af51342..d2d5c1eca61a 100644 --- a/testsuite/tests/typecheck/should_fail/T8883.hs +++ b/testsuite/tests/typecheck/should_fail/T8883.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE TypeFamilies #-} -- #8883 diff --git a/testsuite/tests/typecheck/should_fail/T8883.stderr b/testsuite/tests/typecheck/should_fail/T8883.stderr index c56c434c4c33..6febdaa2b9d5 100644 --- a/testsuite/tests/typecheck/should_fail/T8883.stderr +++ b/testsuite/tests/typecheck/should_fail/T8883.stderr @@ -1,5 +1,5 @@ -T8883.hs:20:1: error: +T8883.hs:21:1: error: • Non type-variable argument in the constraint: Functor (PF a) (Use FlexibleContexts to permit this) • When checking the inferred type diff --git a/testsuite/tests/typecheck/should_fail/T9201.hs b/testsuite/tests/typecheck/should_fail/T9201.hs index 7702fa369c1e..b04162880511 100644 --- a/testsuite/tests/typecheck/should_fail/T9201.hs +++ b/testsuite/tests/typecheck/should_fail/T9201.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE PolyKinds, FunctionalDependencies, MultiParamTypeClasses #-} module T9201 where diff --git a/testsuite/tests/typecheck/should_fail/T9201.stderr b/testsuite/tests/typecheck/should_fail/T9201.stderr index ad873a0d0a06..f0901b4d564d 100644 --- a/testsuite/tests/typecheck/should_fail/T9201.stderr +++ b/testsuite/tests/typecheck/should_fail/T9201.stderr @@ -1,12 +1,12 @@ -T9201.hs:6:17: error: +T9201.hs:7:17: error: • Expected kind ‘x’, but ‘a’ has kind ‘y’ ‘y’ is a rigid type variable bound by the class declaration for ‘MonoidalCCC’ - at T9201.hs:5:20-49 + at T9201.hs:6:20-49 ‘x’ is a rigid type variable bound by the class declaration for ‘MonoidalCCC’ - at T9201.hs:5:20-49 + at T9201.hs:6:20-49 • In the first argument of ‘f’, namely ‘a’ In the second argument of ‘d’, namely ‘(f a)’ In the type signature: ret :: d a (f a) diff --git a/testsuite/tests/typecheck/should_fail/T9858a.hs b/testsuite/tests/typecheck/should_fail/T9858a.hs index b9cbf8fa1add..c61b29baeeb5 100644 --- a/testsuite/tests/typecheck/should_fail/T9858a.hs +++ b/testsuite/tests/typecheck/should_fail/T9858a.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} -- From comment:76 in #9858 -- This exploit still works in GHC 7.10.1. -- By Shachaf Ben-Kiki, Ørjan Johansen and Nathan van Doorn diff --git a/testsuite/tests/typecheck/should_fail/T9858a.stderr b/testsuite/tests/typecheck/should_fail/T9858a.stderr index fcf76ef24725..b179fcf59545 100644 --- a/testsuite/tests/typecheck/should_fail/T9858a.stderr +++ b/testsuite/tests/typecheck/should_fail/T9858a.stderr @@ -1,5 +1,5 @@ -T9858a.hs:20:18: error: +T9858a.hs:21:18: error: • Illegal qualified type: (() :: Constraint, () :: Constraint) => () • In the expansion of type synonym ‘PX’ diff --git a/testsuite/tests/typecheck/should_fail/TcNoNullaryTC.hs b/testsuite/tests/typecheck/should_fail/TcNoNullaryTC.hs index de5e4436f7e7..2928f5ccf5e3 100644 --- a/testsuite/tests/typecheck/should_fail/TcNoNullaryTC.hs +++ b/testsuite/tests/typecheck/should_fail/TcNoNullaryTC.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module NoNullaryTC where class A where diff --git a/testsuite/tests/typecheck/should_fail/TcNoNullaryTC.stderr b/testsuite/tests/typecheck/should_fail/TcNoNullaryTC.stderr index e41b8aa1bda7..15c9cd2ab695 100644 --- a/testsuite/tests/typecheck/should_fail/TcNoNullaryTC.stderr +++ b/testsuite/tests/typecheck/should_fail/TcNoNullaryTC.stderr @@ -1,5 +1,5 @@ -TcNoNullaryTC.hs:3:1: error: +TcNoNullaryTC.hs:4:1: error: • No parameters for class ‘A’ (Enable MultiParamTypeClasses to allow no-parameter classes) • In the class declaration for ‘A’ diff --git a/testsuite/tests/typecheck/should_fail/tcfail044.hs b/testsuite/tests/typecheck/should_fail/tcfail044.hs index b271d0f9770f..09d756693f4b 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail044.hs +++ b/testsuite/tests/typecheck/should_fail/tcfail044.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} -- !!! tcfail044: duplicated type variable in instance decls -- module ShouldFail where diff --git a/testsuite/tests/typecheck/should_fail/tcfail044.stderr b/testsuite/tests/typecheck/should_fail/tcfail044.stderr index 9733cc4fc837..a83ae86d81c5 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail044.stderr +++ b/testsuite/tests/typecheck/should_fail/tcfail044.stderr @@ -1,16 +1,16 @@ -tcfail044.hs:5:20: - Illegal instance declaration for ‘Eq (a -> a)’ - (All instance types must be of the form (T a1 ... an) - where a1 ... an are *distinct type variables*, - and each type variable appears at most once in the instance head. - Use FlexibleInstances if you want to disable this.) - In the instance declaration for ‘Eq (a -> a)’ +tcfail044.hs:6:20: error: + • Illegal instance declaration for ‘Eq (a -> a)’ + (All instance types must be of the form (T a1 ... an) + where a1 ... an are *distinct type variables*, + and each type variable appears at most once in the instance head. + Use FlexibleInstances if you want to disable this.) + • In the instance declaration for ‘Eq (a -> a)’ -tcfail044.hs:8:21: - Illegal instance declaration for ‘Num (a -> a)’ - (All instance types must be of the form (T a1 ... an) - where a1 ... an are *distinct type variables*, - and each type variable appears at most once in the instance head. - Use FlexibleInstances if you want to disable this.) - In the instance declaration for ‘Num (a -> a)’ +tcfail044.hs:9:21: error: + • Illegal instance declaration for ‘Num (a -> a)’ + (All instance types must be of the form (T a1 ... an) + where a1 ... an are *distinct type variables*, + and each type variable appears at most once in the instance head. + Use FlexibleInstances if you want to disable this.) + • In the instance declaration for ‘Num (a -> a)’ diff --git a/testsuite/tests/typecheck/should_fail/tcfail047.hs b/testsuite/tests/typecheck/should_fail/tcfail047.hs index f3cdb19741cb..7c31e3319729 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail047.hs +++ b/testsuite/tests/typecheck/should_fail/tcfail047.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module ShouldFail where class A a where diff --git a/testsuite/tests/typecheck/should_fail/tcfail047.stderr b/testsuite/tests/typecheck/should_fail/tcfail047.stderr index 53eb4defddf1..c1c0dca619b5 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail047.stderr +++ b/testsuite/tests/typecheck/should_fail/tcfail047.stderr @@ -1,8 +1,8 @@ -tcfail047.hs:6:10: - Illegal instance declaration for ‘A (a, (b, c))’ - (All instance types must be of the form (T a1 ... an) - where a1 ... an are *distinct type variables*, - and each type variable appears at most once in the instance head. - Use FlexibleInstances if you want to disable this.) - In the instance declaration for ‘A (a, (b, c))’ +tcfail047.hs:7:10: error: + • Illegal instance declaration for ‘A (a, (b, c))’ + (All instance types must be of the form (T a1 ... an) + where a1 ... an are *distinct type variables*, + and each type variable appears at most once in the instance head. + Use FlexibleInstances if you want to disable this.) + • In the instance declaration for ‘A (a, (b, c))’ diff --git a/testsuite/tests/typecheck/should_fail/tcfail076.hs b/testsuite/tests/typecheck/should_fail/tcfail076.hs index fc4fc011d4b2..384b6d2560db 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail076.hs +++ b/testsuite/tests/typecheck/should_fail/tcfail076.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE RankNTypes #-} {- diff --git a/testsuite/tests/typecheck/should_fail/tcfail076.stderr b/testsuite/tests/typecheck/should_fail/tcfail076.stderr index 47432ae85166..c45eed328e4a 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail076.stderr +++ b/testsuite/tests/typecheck/should_fail/tcfail076.stderr @@ -1,19 +1,19 @@ -tcfail076.hs:18:82: error: +tcfail076.hs:19:82: error: • Couldn't match type ‘res1’ with ‘res’ Expected: m res1 Actual: m res ‘res1’ is a rigid type variable bound by a type expected by the context: forall res1. (b -> m res1) -> m res1 - at tcfail076.hs:18:71-88 + at tcfail076.hs:19:71-88 ‘res’ is a rigid type variable bound by a type expected by the context: forall res. (a -> m res) -> m res - at tcfail076.hs:18:35-96 + at tcfail076.hs:19:35-96 • In the expression: cont a In the first argument of ‘KContT’, namely ‘(\ cont' -> cont a)’ In the expression: KContT (\ cont' -> cont a) • Relevant bindings include - cont' :: b -> m res1 (bound at tcfail076.hs:18:73) - cont :: a -> m res (bound at tcfail076.hs:18:37) + cont' :: b -> m res1 (bound at tcfail076.hs:19:73) + cont :: a -> m res (bound at tcfail076.hs:19:37) diff --git a/testsuite/tests/typecheck/should_fail/tcfail098.hs b/testsuite/tests/typecheck/should_fail/tcfail098.hs index 159e9c8081db..c1c7e93f1ef9 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail098.hs +++ b/testsuite/tests/typecheck/should_fail/tcfail098.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE UndecidableInstances #-} module ShouldFail where diff --git a/testsuite/tests/typecheck/should_fail/tcfail098.stderr b/testsuite/tests/typecheck/should_fail/tcfail098.stderr index 503c3e38983e..a0c2735c267a 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail098.stderr +++ b/testsuite/tests/typecheck/should_fail/tcfail098.stderr @@ -1,10 +1,10 @@ -tcfail098.hs:12:10: error: +tcfail098.hs:13:10: error: • Could not deduce (Bar a0) from the context: Bar a bound by an instance declaration: forall a. Bar a => Bar Bool - at tcfail098.hs:12:10-26 + at tcfail098.hs:13:10-26 The type variable ‘a0’ is ambiguous • In the ambiguity check for an instance declaration To defer the ambiguity check to use sites, enable AllowAmbiguousTypes diff --git a/testsuite/tests/typecheck/should_fail/tcfail116.hs b/testsuite/tests/typecheck/should_fail/tcfail116.hs index 1c32c956d39d..656ffac4e224 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail116.hs +++ b/testsuite/tests/typecheck/should_fail/tcfail116.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module ShouldFail where -- in Haskell 98, methods must mention the class variable diff --git a/testsuite/tests/typecheck/should_fail/tcfail116.stderr b/testsuite/tests/typecheck/should_fail/tcfail116.stderr index 952512686ec1..83a76daf309b 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail116.stderr +++ b/testsuite/tests/typecheck/should_fail/tcfail116.stderr @@ -1,10 +1,10 @@ -tcfail116.hs:6:5: error: +tcfail116.hs:7:5: error: • Could not deduce (Foo a0) from the context: Foo a bound by the type signature for: bug :: forall a. Foo a => () - at tcfail116.hs:6:5-13 + at tcfail116.hs:7:5-13 The type variable ‘a0’ is ambiguous • In the ambiguity check for ‘bug’ To defer the ambiguity check to use sites, enable AllowAmbiguousTypes diff --git a/testsuite/tests/typecheck/should_fail/tcfail117.hs b/testsuite/tests/typecheck/should_fail/tcfail117.hs index 2a5ae9917297..4afc0f527e8f 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail117.hs +++ b/testsuite/tests/typecheck/should_fail/tcfail117.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module ShouldFail where -- Without any extensions enabled both of these should fail diff --git a/testsuite/tests/typecheck/should_fail/tcfail117.stderr b/testsuite/tests/typecheck/should_fail/tcfail117.stderr index e35a2581c847..41caeaea922b 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail117.stderr +++ b/testsuite/tests/typecheck/should_fail/tcfail117.stderr @@ -1,13 +1,13 @@ -tcfail117.hs:5:32: - Can't make a derived instance of ‘Enum N1’: - ‘N1’ must be an enumeration type - (an enumeration consists of one or more nullary, non-GADT constructors) - Try GeneralizedNewtypeDeriving for GHC's newtype-deriving extension - In the newtype declaration for ‘N1’ +tcfail117.hs:6:32: error: + • Can't make a derived instance of ‘Enum N1’: + ‘N1’ must be an enumeration type + (an enumeration consists of one or more nullary, non-GADT constructors) + Try GeneralizedNewtypeDeriving for GHC's newtype-deriving extension + • In the newtype declaration for ‘N1’ -tcfail117.hs:6:32: - Can't make a derived instance of ‘Enum N2’: - ‘N2’ must be an enumeration type - (an enumeration consists of one or more nullary, non-GADT constructors) - In the data declaration for ‘N2’ +tcfail117.hs:7:32: error: + • Can't make a derived instance of ‘Enum N2’: + ‘N2’ must be an enumeration type + (an enumeration consists of one or more nullary, non-GADT constructors) + • In the data declaration for ‘N2’ diff --git a/testsuite/tests/typecheck/should_fail/tcfail122.hs b/testsuite/tests/typecheck/should_fail/tcfail122.hs index 2594ca6e2421..77455c7c7b65 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail122.hs +++ b/testsuite/tests/typecheck/should_fail/tcfail122.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE RankNTypes, KindSignatures #-} module ShouldFail where diff --git a/testsuite/tests/typecheck/should_fail/tcfail122.stderr b/testsuite/tests/typecheck/should_fail/tcfail122.stderr index 39507bdbeb4b..9aed03214bc7 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail122.stderr +++ b/testsuite/tests/typecheck/should_fail/tcfail122.stderr @@ -1,5 +1,5 @@ -tcfail122.hs:8:9: error: +tcfail122.hs:9:9: error: • Couldn't match kind ‘*’ with ‘* -> *’ When matching types c0 :: (* -> *) -> * @@ -16,4 +16,4 @@ tcfail122.hs:8:9: error: = [undefined :: forall a b. a b, undefined :: forall (c :: (* -> *) -> *) (d :: * -> *). c d] • Relevant bindings include - foo :: [a b] (bound at tcfail122.hs:7:1) + foo :: [a b] (bound at tcfail122.hs:8:1) diff --git a/testsuite/tests/typecheck/should_fail/tcfail132.hs b/testsuite/tests/typecheck/should_fail/tcfail132.hs index 910fc2267c74..c241c18e4ca0 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail132.hs +++ b/testsuite/tests/typecheck/should_fail/tcfail132.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} -- Fails with a kind error. -- The current error message was rather horrible (trac bug #312): -- diff --git a/testsuite/tests/typecheck/should_fail/tcfail132.stderr b/testsuite/tests/typecheck/should_fail/tcfail132.stderr index 92f7c2ab524b..a026a3a9f97f 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail132.stderr +++ b/testsuite/tests/typecheck/should_fail/tcfail132.stderr @@ -1,5 +1,5 @@ -tcfail132.hs:17:37: error: +tcfail132.hs:18:37: error: • Couldn't match kind ‘*’ with ‘* -> *’ Expected kind ‘* -> * -> * -> *’, but ‘Object f' f t’ has kind ‘* -> * -> *’ @@ -7,7 +7,7 @@ tcfail132.hs:17:37: error: In the type ‘T (Object f' f t) (DUnit t)’ In the type declaration for ‘LiftObject’ -tcfail132.hs:17:53: error: +tcfail132.hs:18:53: error: • Couldn't match kind ‘*’ with ‘* -> *’ Expected kind ‘* -> * -> * -> *’, but ‘DUnit t’ has kind ‘* -> * -> *’ diff --git a/testsuite/tests/typecheck/should_fail/tcfail139.hs b/testsuite/tests/typecheck/should_fail/tcfail139.hs index af21c8afba61..5532523a7c0f 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail139.hs +++ b/testsuite/tests/typecheck/should_fail/tcfail139.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} -- Should be rejected by Haskell 98 module Foo where diff --git a/testsuite/tests/typecheck/should_fail/tcfail139.stderr b/testsuite/tests/typecheck/should_fail/tcfail139.stderr index e97ff3bf8a06..496df9488f63 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail139.stderr +++ b/testsuite/tests/typecheck/should_fail/tcfail139.stderr @@ -1,7 +1,7 @@ -tcfail139.hs:6:10: - Illegal instance declaration for ‘Bounded Foo’ - (All instance types must be of the form (T t1 ... tn) - where T is not a synonym. - Use TypeSynonymInstances if you want to disable this.) - In the instance declaration for ‘Bounded Foo’ +tcfail139.hs:7:10: error: + • Illegal instance declaration for ‘Bounded Foo’ + (All instance types must be of the form (T t1 ... tn) + where T is not a synonym. + Use TypeSynonymInstances if you want to disable this.) + • In the instance declaration for ‘Bounded Foo’ diff --git a/testsuite/tests/typecheck/should_fail/tcfail140.hs b/testsuite/tests/typecheck/should_fail/tcfail140.hs index 8a4bb7dbe5a8..d897f138de62 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail140.hs +++ b/testsuite/tests/typecheck/should_fail/tcfail140.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} -- GHC 6.4 gave pretty horrible error messages -- for some of these examples -- c.f. SourceForge [ ghc-Bugs-1231273 ] confusing error diff --git a/testsuite/tests/typecheck/should_fail/tcfail140.stderr b/testsuite/tests/typecheck/should_fail/tcfail140.stderr index 8bce6238c638..d40b3171307a 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail140.stderr +++ b/testsuite/tests/typecheck/should_fail/tcfail140.stderr @@ -1,38 +1,38 @@ -tcfail140.hs:10:7: error: +tcfail140.hs:11:7: error: • Couldn't match expected type ‘t0 -> t’ with actual type ‘Int’ • The function ‘f’ is applied to two value arguments, but its type ‘Int -> Int’ has only one In the expression: f 3 9 In an equation for ‘bar’: bar = f 3 9 - • Relevant bindings include bar :: t (bound at tcfail140.hs:10:1) + • Relevant bindings include bar :: t (bound at tcfail140.hs:11:1) -tcfail140.hs:12:10: error: +tcfail140.hs:13:10: error: • Couldn't match expected type ‘t1 -> t’ with actual type ‘Int’ • The function ‘f’ is applied to two value arguments, but its type ‘Int -> Int’ has only one In the expression: 3 `f` 4 In an equation for ‘rot’: rot xs = 3 `f` 4 • Relevant bindings include - rot :: p -> t (bound at tcfail140.hs:12:1) + rot :: p -> t (bound at tcfail140.hs:13:1) -tcfail140.hs:14:15: error: +tcfail140.hs:15:15: error: • Couldn't match expected type ‘a -> b’ with actual type ‘Int’ • In the first argument of ‘map’, namely ‘(3 `f`)’ In the expression: map (3 `f`) xs In an equation for ‘bot’: bot xs = map (3 `f`) xs • Relevant bindings include - xs :: [a] (bound at tcfail140.hs:14:5) - bot :: [a] -> [b] (bound at tcfail140.hs:14:1) + xs :: [a] (bound at tcfail140.hs:15:5) + bot :: [a] -> [b] (bound at tcfail140.hs:15:1) -tcfail140.hs:16:8: error: +tcfail140.hs:17:8: error: • The constructor ‘Just’ should have 1 argument, but has been given none • In the pattern: Just The lambda expression ‘\ Just x -> x’ has two value arguments, but its type ‘Maybe a -> a’ has only one In the expression: (\ Just x -> x) :: Maybe a -> a -tcfail140.hs:19:1: error: +tcfail140.hs:20:1: error: • Couldn't match expected type ‘Int’ with actual type ‘p0 -> Bool’ • The equation(s) for ‘g’ have two value arguments, but its type ‘Int -> Int’ has only one diff --git a/testsuite/tests/typecheck/should_fail/tcfail142.hs b/testsuite/tests/typecheck/should_fail/tcfail142.hs index a628b0e335ad..246d568e015e 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail142.hs +++ b/testsuite/tests/typecheck/should_fail/tcfail142.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE MultiParamTypeClasses #-} -- Tests top-level ambiguity resolution diff --git a/testsuite/tests/typecheck/should_fail/tcfail142.stderr b/testsuite/tests/typecheck/should_fail/tcfail142.stderr index ac36ffb5e081..ecb22021f382 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail142.stderr +++ b/testsuite/tests/typecheck/should_fail/tcfail142.stderr @@ -1,10 +1,10 @@ -tcfail142.hs:18:8: error: +tcfail142.hs:19:8: error: • Could not deduce (Bar a0 r) from the context: Bar a r bound by the type signature for: bar :: forall a r. Bar a r => r -> () - at tcfail142.hs:18:8-25 + at tcfail142.hs:19:8-25 The type variable ‘a0’ is ambiguous • In the ambiguity check for ‘bar’ To defer the ambiguity check to use sites, enable AllowAmbiguousTypes diff --git a/testsuite/tests/typecheck/should_fail/tcfail143.hs b/testsuite/tests/typecheck/should_fail/tcfail143.hs index 55b45eca3171..9051c629da48 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail143.hs +++ b/testsuite/tests/typecheck/should_fail/tcfail143.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE UndecidableInstances, FlexibleInstances, MultiParamTypeClasses, FunctionalDependencies #-} diff --git a/testsuite/tests/typecheck/should_fail/tcfail143.stderr b/testsuite/tests/typecheck/should_fail/tcfail143.stderr index 576ac1903db3..841504d3f981 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail143.stderr +++ b/testsuite/tests/typecheck/should_fail/tcfail143.stderr @@ -1,8 +1,8 @@ -tcfail143.hs:29:9: error: +tcfail143.hs:30:9: error: • Couldn't match type ‘S Z’ with ‘Z’ arising from a functional dependency between: constraint ‘MinMax (S Z) Z Z Z’ arising from a use of ‘extend’ - instance ‘MinMax a Z Z a’ at tcfail143.hs:11:10-23 + instance ‘MinMax a Z Z a’ at tcfail143.hs:12:10-23 • In the expression: n1 `extend` n0 In an equation for ‘t2’: t2 = n1 `extend` n0 diff --git a/testsuite/tests/typecheck/should_fail/tcfail150.hs b/testsuite/tests/typecheck/should_fail/tcfail150.hs index cc2ca034efe4..dc10e56727e5 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail150.hs +++ b/testsuite/tests/typecheck/should_fail/tcfail150.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module ShouldFail where -- !!! constraining the type variable in a class head is illegal diff --git a/testsuite/tests/typecheck/should_fail/tcfail150.stderr b/testsuite/tests/typecheck/should_fail/tcfail150.stderr index fe14a3ab1c5a..50a2793add5e 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail150.stderr +++ b/testsuite/tests/typecheck/should_fail/tcfail150.stderr @@ -1,5 +1,5 @@ -tcfail150.hs:6:3: error: +tcfail150.hs:7:3: error: • Constraint ‘Eq a’ in the type of ‘op’ constrains only the class type variables Enable ConstrainedClassMethods to allow it diff --git a/testsuite/tests/typecheck/should_fail/tcfail154.hs b/testsuite/tests/typecheck/should_fail/tcfail154.hs index 6e3161bd462e..f7e8bd1b8286 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail154.hs +++ b/testsuite/tests/typecheck/should_fail/tcfail154.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE MultiParamTypeClasses #-} module ShouldFail where diff --git a/testsuite/tests/typecheck/should_fail/tcfail154.stderr b/testsuite/tests/typecheck/should_fail/tcfail154.stderr index 3e613201f700..a4bda5998e64 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail154.stderr +++ b/testsuite/tests/typecheck/should_fail/tcfail154.stderr @@ -1,5 +1,5 @@ -tcfail154.hs:12:10: error: +tcfail154.hs:13:10: error: • Variable ‘a’ occurs more often in the constraint ‘C a a’ than in the instance head ‘Eq (T a)’ (Use UndecidableInstances to permit this) diff --git a/testsuite/tests/typecheck/should_fail/tcfail158.hs b/testsuite/tests/typecheck/should_fail/tcfail158.hs index 95af345b364f..f87ecbc53ab7 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail158.hs +++ b/testsuite/tests/typecheck/should_fail/tcfail158.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE ExplicitForAll #-} -- This one actually crashed in 6.4.1 diff --git a/testsuite/tests/typecheck/should_fail/tcfail158.stderr b/testsuite/tests/typecheck/should_fail/tcfail158.stderr index c4734657404f..526db0a6eaa3 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail158.stderr +++ b/testsuite/tests/typecheck/should_fail/tcfail158.stderr @@ -1,5 +1,5 @@ -tcfail158.hs:14:19: error: +tcfail158.hs:15:19: error: • Expecting one more argument to ‘Val v’ Expected a type, but ‘Val v’ has kind ‘* -> *’ • In the type signature: bar :: forall v. Val v diff --git a/testsuite/tests/typecheck/should_fail/tcfail166.hs b/testsuite/tests/typecheck/should_fail/tcfail166.hs index 5a2d4b8df7f7..31fa9fad2087 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail166.hs +++ b/testsuite/tests/typecheck/should_fail/tcfail166.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} -- Without -XScopedTypeVariables, this should fail module ShouldFail where diff --git a/testsuite/tests/typecheck/should_fail/tcfail166.stderr b/testsuite/tests/typecheck/should_fail/tcfail166.stderr index 5cc11d4a4be0..ab8805183d18 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail166.stderr +++ b/testsuite/tests/typecheck/should_fail/tcfail166.stderr @@ -1,5 +1,5 @@ -tcfail166.hs:5:13: error: +tcfail166.hs:6:13: error: Illegal symbol ‘forall’ in type Perhaps you intended to use RankNTypes or a similar language extension to enable explicit-forall syntax: forall <tvs>. <type> diff --git a/testsuite/tests/typecheck/should_fail/tcfail173.hs b/testsuite/tests/typecheck/should_fail/tcfail173.hs index bad14bd5395e..0221aa74afc6 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail173.hs +++ b/testsuite/tests/typecheck/should_fail/tcfail173.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module ShouldFail where diff --git a/testsuite/tests/typecheck/should_fail/tcfail173.stderr b/testsuite/tests/typecheck/should_fail/tcfail173.stderr index 70a22c3af91a..a3da917f2730 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail173.stderr +++ b/testsuite/tests/typecheck/should_fail/tcfail173.stderr @@ -1,4 +1,4 @@ -tcfail173.hs:5:12: +tcfail173.hs:6:12: error: Illegal declaration of a type or class operator ‘<.>’ Use TypeOperators to declare operators in type and declarations diff --git a/testsuite/tests/typecheck/should_fail/tcfail183.hs b/testsuite/tests/typecheck/should_fail/tcfail183.hs index d46d87ad7c4e..0e21d7234553 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail183.hs +++ b/testsuite/tests/typecheck/should_fail/tcfail183.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module ShouldCompile where diff --git a/testsuite/tests/typecheck/should_fail/tcfail183.stderr b/testsuite/tests/typecheck/should_fail/tcfail183.stderr index 7a0e2ab346bb..96245ce100f5 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail183.stderr +++ b/testsuite/tests/typecheck/should_fail/tcfail183.stderr @@ -1,5 +1,5 @@ -tcfail183.hs:4:30: error: +tcfail183.hs:5:30: error: Illegal symbol ‘forall’ in type Perhaps you intended to use RankNTypes or a similar language extension to enable explicit-forall syntax: forall <tvs>. <type> diff --git a/testsuite/tests/typecheck/should_fail/tcfail184.hs b/testsuite/tests/typecheck/should_fail/tcfail184.hs index 210a9c7c9b11..17ae2f575665 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail184.hs +++ b/testsuite/tests/typecheck/should_fail/tcfail184.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# OPTIONS_GHC -XScopedTypeVariables #-} -- We don't actually want scoped type variables, but this flag makes the diff --git a/testsuite/tests/typecheck/should_fail/tcfail184.stderr b/testsuite/tests/typecheck/should_fail/tcfail184.stderr index fd6f1fdefd7f..8a1117caea93 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail184.stderr +++ b/testsuite/tests/typecheck/should_fail/tcfail184.stderr @@ -1,5 +1,5 @@ -tcfail184.hs:8:19: error: +tcfail184.hs:9:19: error: • Illegal polymorphic type: forall a. Ord a => [a] -> [a] Perhaps you intended to use RankNTypes • In the definition of data constructor ‘MkSwizzle’ diff --git a/testsuite/tests/typecheck/should_fail/tcfail195.hs b/testsuite/tests/typecheck/should_fail/tcfail195.hs index 4c2408e8ba1a..0b06236a52cd 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail195.hs +++ b/testsuite/tests/typecheck/should_fail/tcfail195.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE RankNTypes, GADTs #-} module ShouldFail where diff --git a/testsuite/tests/typecheck/should_fail/tcfail195.stderr b/testsuite/tests/typecheck/should_fail/tcfail195.stderr index 1fa821fbaca0..93a4b8f92f16 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail195.stderr +++ b/testsuite/tests/typecheck/should_fail/tcfail195.stderr @@ -1,5 +1,5 @@ -tcfail195.hs:6:3: error: +tcfail195.hs:7:3: error: • Illegal polymorphic type: forall a. a • In the definition of data constructor ‘Foo’ In the data type declaration for ‘Foo’ diff --git a/testsuite/tests/typecheck/should_fail/tcfail209.hs b/testsuite/tests/typecheck/should_fail/tcfail209.hs index f4f092223142..e91b16dc1b35 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail209.hs +++ b/testsuite/tests/typecheck/should_fail/tcfail209.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module FancyContextsWithoutExtension1 where type Showish = Show diff --git a/testsuite/tests/typecheck/should_fail/tcfail209.stderr b/testsuite/tests/typecheck/should_fail/tcfail209.stderr index 1d2f315494f9..f52d2a8f7901 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail209.stderr +++ b/testsuite/tests/typecheck/should_fail/tcfail209.stderr @@ -1,5 +1,5 @@ -tcfail209.hs:3:1: error: +tcfail209.hs:4:1: error: • Illegal constraint synonym of kind: ‘* -> Constraint’ (Use ConstraintKinds to permit this) • In the type synonym declaration for ‘Showish’ diff --git a/testsuite/tests/typecheck/should_fail/tcfail209a.hs b/testsuite/tests/typecheck/should_fail/tcfail209a.hs index 90abb73520ee..ba0b19299107 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail209a.hs +++ b/testsuite/tests/typecheck/should_fail/tcfail209a.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} module TcFail209a where g :: ((Show a, Num a), Eq a) => a -> a diff --git a/testsuite/tests/typecheck/should_fail/tcfail209a.stderr b/testsuite/tests/typecheck/should_fail/tcfail209a.stderr index 1ccd64ff2bd4..aad518014eb2 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail209a.stderr +++ b/testsuite/tests/typecheck/should_fail/tcfail209a.stderr @@ -1,6 +1,5 @@ -tcfail209a.hs:3:6: error: +tcfail209a.hs:4:6: error: • Illegal tuple constraint: (Show a, Num a) (Use ConstraintKinds to permit this) - • In the type signature: - g :: ((Show a, Num a), Eq a) => a -> a + • In the type signature: g :: ((Show a, Num a), Eq a) => a -> a diff --git a/testsuite/tests/typecheck/should_run/TypeOf.hs b/testsuite/tests/typecheck/should_run/TypeOf.hs index 37113bfe8065..0c3ac14b0f49 100644 --- a/testsuite/tests/typecheck/should_run/TypeOf.hs +++ b/testsuite/tests/typecheck/should_run/TypeOf.hs @@ -1,3 +1,4 @@ +{-# LANGUAGE Haskell2010 #-} {-# LANGUAGE DataKinds, UnicodeSyntax #-} {-# OPTIONS -Wno-star-is-type #-} -- GitLab