From ee4a92de23254f0c333071503758e93695205757 Mon Sep 17 00:00:00 2001 From: Francesco Gazzetta Date: Mon, 2 May 2022 12:17:32 +0200 Subject: [PATCH] Remove "colon specifier is experimental feature" Same for "visibility is experimental feature" With #7270 fixed, it's time to allow hackage uploads. PWTExperimental is not used anymore, but for now I'm keeping it in case we add other experimental features in the future, so we don't keep removing and adding it (pushing CPP on users). Since it isn't used though there is no way to run cabal-testsuite/PackageTests/DuplicateExperimental so I'm just removing that test. Closes #6801 --- .../src/Distribution/Types/Dependency.hs | 1 - .../Distribution/Types/LibraryVisibility.hs | 1 - Cabal-syntax/src/Distribution/Types/Mixin.hs | 1 - .../ParserTests/regressions/issue-5846.format | 4 --- .../regressions/issue-6083-a.format | 2 -- .../regressions/issue-6083-b.format | 1 - .../regressions/issue-6083-pkg-pkg.format | 1 - .../regressions/public-multilib-1.cabal | 2 +- .../regressions/public-multilib-1.check | 1 - .../regressions/public-multilib-2.cabal | 2 +- .../regressions/public-multilib-2.check | 1 - .../DuplicateExperimental/Four.hs | 1 - .../DuplicateExperimental/Main.hs | 6 ---- .../PackageTests/DuplicateExperimental/One.hs | 1 - .../DuplicateExperimental/Three.hs | 1 - .../PackageTests/DuplicateExperimental/Two.hs | 1 - .../DuplicateExperimental/cabal.project | 2 -- .../DuplicateExperimental/duplicate.cabal | 35 ------------------- .../DuplicateExperimental/setup.out | 2 -- .../DuplicateExperimental/setup.test.hs | 9 ----- .../MultipleLibraries/Successful/cabal.out | 2 -- .../MultipleLibraries/T6083Post/cabal.out | 2 -- .../T6083PostMixin/cabal.out | 3 -- .../MultipleLibraries/T6083Pre/cabal.out | 2 -- .../MultipleLibraries/T6083PreMixin/cabal.out | 2 -- .../MultipleLibraries/T6894/cabal.out | 2 -- .../MultipleLibraries/T6894/setup.cabal.out | 1 - .../MultipleLibraries/T6894/setup.out | 1 - .../MultipleLibraries/T7270/cabal.out | 2 -- 29 files changed, 2 insertions(+), 90 deletions(-) delete mode 100644 cabal-testsuite/PackageTests/DuplicateExperimental/Four.hs delete mode 100644 cabal-testsuite/PackageTests/DuplicateExperimental/Main.hs delete mode 100644 cabal-testsuite/PackageTests/DuplicateExperimental/One.hs delete mode 100644 cabal-testsuite/PackageTests/DuplicateExperimental/Three.hs delete mode 100644 cabal-testsuite/PackageTests/DuplicateExperimental/Two.hs delete mode 100644 cabal-testsuite/PackageTests/DuplicateExperimental/cabal.project delete mode 100644 cabal-testsuite/PackageTests/DuplicateExperimental/duplicate.cabal delete mode 100644 cabal-testsuite/PackageTests/DuplicateExperimental/setup.out delete mode 100644 cabal-testsuite/PackageTests/DuplicateExperimental/setup.test.hs diff --git a/Cabal-syntax/src/Distribution/Types/Dependency.hs b/Cabal-syntax/src/Distribution/Types/Dependency.hs index 321ebc020f7..fbe2ab978a1 100644 --- a/Cabal-syntax/src/Distribution/Types/Dependency.hs +++ b/Cabal-syntax/src/Distribution/Types/Dependency.hs @@ -145,7 +145,6 @@ instance Parsec Dependency where libs <- option mainLibSet $ do _ <- char ':' versionGuardMultilibs - parsecWarning PWTExperimental "colon specifier is experimental feature (issue #5660)" NES.singleton <$> parseLib <|> parseMultipleLibs spaces -- https://github.com/haskell/cabal/issues/5846 diff --git a/Cabal-syntax/src/Distribution/Types/LibraryVisibility.hs b/Cabal-syntax/src/Distribution/Types/LibraryVisibility.hs index 129b28ede8d..19e63892477 100644 --- a/Cabal-syntax/src/Distribution/Types/LibraryVisibility.hs +++ b/Cabal-syntax/src/Distribution/Types/LibraryVisibility.hs @@ -33,7 +33,6 @@ instance Pretty LibraryVisibility where instance Parsec LibraryVisibility where parsec = do name <- P.munch1 isAlpha - parsecWarning PWTExperimental "visibility is experimental feature (issue #5660)" case name of "public" -> return LibraryVisibilityPublic "private" -> return LibraryVisibilityPrivate diff --git a/Cabal-syntax/src/Distribution/Types/Mixin.hs b/Cabal-syntax/src/Distribution/Types/Mixin.hs index 2694c580f67..bf8097377bd 100644 --- a/Cabal-syntax/src/Distribution/Types/Mixin.hs +++ b/Cabal-syntax/src/Distribution/Types/Mixin.hs @@ -63,7 +63,6 @@ instance Parsec Mixin where ln <- P.option LMainLibName $ do _ <- P.char ':' versionGuardMultilibs - parsecWarning PWTExperimental "colon specifier is experimental feature (issue #5660)" LSubLibName <$> parsec P.spaces incl <- parsec diff --git a/Cabal-tests/tests/ParserTests/regressions/issue-5846.format b/Cabal-tests/tests/ParserTests/regressions/issue-5846.format index 42194892150..749a9c20524 100644 --- a/Cabal-tests/tests/ParserTests/regressions/issue-5846.format +++ b/Cabal-tests/tests/ParserTests/regressions/issue-5846.format @@ -1,7 +1,3 @@ -issue-5846.cabal:11:23: colon specifier is experimental feature (issue #5660) -issue-5846.cabal:10:23: colon specifier is experimental feature (issue #5660) -issue-5846.cabal:7:23: colon specifier is experimental feature (issue #5660) -issue-5846.cabal:8:23: colon specifier is experimental feature (issue #5660) cabal-version: 3.0 name: issue version: 5846 diff --git a/Cabal-tests/tests/ParserTests/regressions/issue-6083-a.format b/Cabal-tests/tests/ParserTests/regressions/issue-6083-a.format index a663df4a0dd..e5cac8f5ee2 100644 --- a/Cabal-tests/tests/ParserTests/regressions/issue-6083-a.format +++ b/Cabal-tests/tests/ParserTests/regressions/issue-6083-a.format @@ -1,5 +1,3 @@ -issue-6083-a.cabal:19:31: colon specifier is experimental feature (issue #5660) -issue-6083-a.cabal:8:30: colon specifier is experimental feature (issue #5660) cabal-version: 3.4 name: issue version: 6083 diff --git a/Cabal-tests/tests/ParserTests/regressions/issue-6083-b.format b/Cabal-tests/tests/ParserTests/regressions/issue-6083-b.format index 3b4a3b99620..d209d572be0 100644 --- a/Cabal-tests/tests/ParserTests/regressions/issue-6083-b.format +++ b/Cabal-tests/tests/ParserTests/regressions/issue-6083-b.format @@ -1,4 +1,3 @@ -issue-6083-b.cabal:19:31: colon specifier is experimental feature (issue #5660) cabal-version: 3.0 name: issue version: 6083 diff --git a/Cabal-tests/tests/ParserTests/regressions/issue-6083-pkg-pkg.format b/Cabal-tests/tests/ParserTests/regressions/issue-6083-pkg-pkg.format index 7f8cf215865..f0535dd28da 100644 --- a/Cabal-tests/tests/ParserTests/regressions/issue-6083-pkg-pkg.format +++ b/Cabal-tests/tests/ParserTests/regressions/issue-6083-pkg-pkg.format @@ -1,4 +1,3 @@ -issue-6083-pkg-pkg.cabal:9:27: colon specifier is experimental feature (issue #5660) cabal-version: 3.0 name: issue version: 6083 diff --git a/Cabal-tests/tests/ParserTests/regressions/public-multilib-1.cabal b/Cabal-tests/tests/ParserTests/regressions/public-multilib-1.cabal index 0b900e43b4d..ba10ba6ea73 100644 --- a/Cabal-tests/tests/ParserTests/regressions/public-multilib-1.cabal +++ b/Cabal-tests/tests/ParserTests/regressions/public-multilib-1.cabal @@ -1,7 +1,7 @@ cabal-version: 3.0 name: public-multilib1 version: 0 -synopsis: public-multilibs are not polished enough for Hackage +synopsis: public-multilibs category: Tests license: MIT diff --git a/Cabal-tests/tests/ParserTests/regressions/public-multilib-1.check b/Cabal-tests/tests/ParserTests/regressions/public-multilib-1.check index c1ba39a46b7..3d4f13970d7 100644 --- a/Cabal-tests/tests/ParserTests/regressions/public-multilib-1.check +++ b/Cabal-tests/tests/ParserTests/regressions/public-multilib-1.check @@ -1,3 +1,2 @@ -public-multilib-1.cabal:16:27: visibility is experimental feature (issue #5660) No 'maintainer' field. No 'description' field. diff --git a/Cabal-tests/tests/ParserTests/regressions/public-multilib-2.cabal b/Cabal-tests/tests/ParserTests/regressions/public-multilib-2.cabal index e7778a8a2e9..fe0d60a561c 100644 --- a/Cabal-tests/tests/ParserTests/regressions/public-multilib-2.cabal +++ b/Cabal-tests/tests/ParserTests/regressions/public-multilib-2.cabal @@ -1,7 +1,7 @@ cabal-version: 3.0 name: public-multilib1 version: 0 -synopsis: public-multilibs are not polished enough for Hackage +synopsis: public-multilibs category: Tests license: MIT diff --git a/Cabal-tests/tests/ParserTests/regressions/public-multilib-2.check b/Cabal-tests/tests/ParserTests/regressions/public-multilib-2.check index 66f40145129..3d4f13970d7 100644 --- a/Cabal-tests/tests/ParserTests/regressions/public-multilib-2.check +++ b/Cabal-tests/tests/ParserTests/regressions/public-multilib-2.check @@ -1,3 +1,2 @@ -public-multilib-2.cabal:12:15: colon specifier is experimental feature (issue #5660) No 'maintainer' field. No 'description' field. diff --git a/cabal-testsuite/PackageTests/DuplicateExperimental/Four.hs b/cabal-testsuite/PackageTests/DuplicateExperimental/Four.hs deleted file mode 100644 index eae11859189..00000000000 --- a/cabal-testsuite/PackageTests/DuplicateExperimental/Four.hs +++ /dev/null @@ -1 +0,0 @@ -module Four where diff --git a/cabal-testsuite/PackageTests/DuplicateExperimental/Main.hs b/cabal-testsuite/PackageTests/DuplicateExperimental/Main.hs deleted file mode 100644 index 75684e917e3..00000000000 --- a/cabal-testsuite/PackageTests/DuplicateExperimental/Main.hs +++ /dev/null @@ -1,6 +0,0 @@ -module Main where - -import One -import Two -import Three -import Four diff --git a/cabal-testsuite/PackageTests/DuplicateExperimental/One.hs b/cabal-testsuite/PackageTests/DuplicateExperimental/One.hs deleted file mode 100644 index db76b316e19..00000000000 --- a/cabal-testsuite/PackageTests/DuplicateExperimental/One.hs +++ /dev/null @@ -1 +0,0 @@ -module One where diff --git a/cabal-testsuite/PackageTests/DuplicateExperimental/Three.hs b/cabal-testsuite/PackageTests/DuplicateExperimental/Three.hs deleted file mode 100644 index efaea8d41a8..00000000000 --- a/cabal-testsuite/PackageTests/DuplicateExperimental/Three.hs +++ /dev/null @@ -1 +0,0 @@ -module Three where diff --git a/cabal-testsuite/PackageTests/DuplicateExperimental/Two.hs b/cabal-testsuite/PackageTests/DuplicateExperimental/Two.hs deleted file mode 100644 index 4738ff7fc49..00000000000 --- a/cabal-testsuite/PackageTests/DuplicateExperimental/Two.hs +++ /dev/null @@ -1 +0,0 @@ -module Two where diff --git a/cabal-testsuite/PackageTests/DuplicateExperimental/cabal.project b/cabal-testsuite/PackageTests/DuplicateExperimental/cabal.project deleted file mode 100644 index 8834d04402a..00000000000 --- a/cabal-testsuite/PackageTests/DuplicateExperimental/cabal.project +++ /dev/null @@ -1,2 +0,0 @@ -packages: - ./ diff --git a/cabal-testsuite/PackageTests/DuplicateExperimental/duplicate.cabal b/cabal-testsuite/PackageTests/DuplicateExperimental/duplicate.cabal deleted file mode 100644 index 1b00acbf04b..00000000000 --- a/cabal-testsuite/PackageTests/DuplicateExperimental/duplicate.cabal +++ /dev/null @@ -1,35 +0,0 @@ -cabal-version: 3.0 -name: duplicate -version: 0 -synopsis: Test of de-duping multiple warnings for experimental features -category: Tests -license: MIT - -library - build-depends: base, one, two, three, four - exposed-modules: Main - default-language: Haskell2010 - -library one - visibility: public - exposed-modules: One - build-depends: base - default-language: Haskell2010 - -library two - visibility: public - exposed-modules: Two - build-depends: base - default-language: Haskell2010 - -library three - visibility: public - exposed-modules: Three - build-depends: base - default-language: Haskell2010 - -library four - visibility: public - exposed-modules: Four - build-depends: base - default-language: Haskell2010 diff --git a/cabal-testsuite/PackageTests/DuplicateExperimental/setup.out b/cabal-testsuite/PackageTests/DuplicateExperimental/setup.out deleted file mode 100644 index 65f17dd1e53..00000000000 --- a/cabal-testsuite/PackageTests/DuplicateExperimental/setup.out +++ /dev/null @@ -1,2 +0,0 @@ -# cabal build -# cabal build diff --git a/cabal-testsuite/PackageTests/DuplicateExperimental/setup.test.hs b/cabal-testsuite/PackageTests/DuplicateExperimental/setup.test.hs deleted file mode 100644 index 3074e5ac50a..00000000000 --- a/cabal-testsuite/PackageTests/DuplicateExperimental/setup.test.hs +++ /dev/null @@ -1,9 +0,0 @@ -import Test.Cabal.Prelude -main = cabalTest $ do - -- check output is summarized in -v1 (-v normal) - res <- cabal' "build" ["--only-configure","duplicate","-vnormal"] - assertOutputContains "(and 3 more occurrences)" res - - -- check output is _not_ summarized in -v2 (verbose) - res <- cabal' "build" ["--only-configure","duplicate","-vverbose"] - assertOutputDoesNotContain "(and 3 more occurrences)" res diff --git a/cabal-testsuite/PackageTests/MultipleLibraries/Successful/cabal.out b/cabal-testsuite/PackageTests/MultipleLibraries/Successful/cabal.out index 71c776d0232..75892cd5752 100644 --- a/cabal-testsuite/PackageTests/MultipleLibraries/Successful/cabal.out +++ b/cabal-testsuite/PackageTests/MultipleLibraries/Successful/cabal.out @@ -4,11 +4,9 @@ Build profile: -w ghc- -O1 In order, the following will be built: - pkg-def-0.1.0.0 (lib:publib) (first run) - pkg-abc-0.1.0.0 (exe:program) (first run) -Warning: pkg-def.cabal:10:27: visibility is experimental feature (issue #5660) Configuring library 'publib' for pkg-def-0.1.0.0.. Preprocessing library 'publib' for pkg-def-0.1.0.0.. Building library 'publib' for pkg-def-0.1.0.0.. -Warning: pkg-abc.cabal:10:15: colon specifier is experimental feature (issue #5660) Configuring executable 'program' for pkg-abc-0.1.0.0.. Preprocessing executable 'program' for pkg-abc-0.1.0.0.. Building executable 'program' for pkg-abc-0.1.0.0.. diff --git a/cabal-testsuite/PackageTests/MultipleLibraries/T6083Post/cabal.out b/cabal-testsuite/PackageTests/MultipleLibraries/T6083Post/cabal.out index f82d1770636..2ceb5183c98 100644 --- a/cabal-testsuite/PackageTests/MultipleLibraries/T6083Post/cabal.out +++ b/cabal-testsuite/PackageTests/MultipleLibraries/T6083Post/cabal.out @@ -4,11 +4,9 @@ Build profile: -w ghc- -O1 In order, the following will be built: - pkg-def-0.1.0.0 (lib) (first run) - pkg-abc-0.1.0.0 (exe:program) (first run) -Warning: pkg-def.cabal:13:27: visibility is experimental feature (issue #5660) Configuring library for pkg-def-0.1.0.0.. Preprocessing library for pkg-def-0.1.0.0.. Building library for pkg-def-0.1.0.0.. -Warning: pkg-abc.cabal:19:15: colon specifier is experimental feature (issue #5660) Configuring executable 'program' for pkg-abc-0.1.0.0.. Preprocessing executable 'program' for pkg-abc-0.1.0.0.. Building executable 'program' for pkg-abc-0.1.0.0.. diff --git a/cabal-testsuite/PackageTests/MultipleLibraries/T6083PostMixin/cabal.out b/cabal-testsuite/PackageTests/MultipleLibraries/T6083PostMixin/cabal.out index e6c014b160b..2ceb5183c98 100644 --- a/cabal-testsuite/PackageTests/MultipleLibraries/T6083PostMixin/cabal.out +++ b/cabal-testsuite/PackageTests/MultipleLibraries/T6083PostMixin/cabal.out @@ -4,12 +4,9 @@ Build profile: -w ghc- -O1 In order, the following will be built: - pkg-def-0.1.0.0 (lib) (first run) - pkg-abc-0.1.0.0 (exe:program) (first run) -Warning: pkg-def.cabal:13:27: visibility is experimental feature (issue #5660) Configuring library for pkg-def-0.1.0.0.. Preprocessing library for pkg-def-0.1.0.0.. Building library for pkg-def-0.1.0.0.. -Warning: pkg-abc.cabal:15:29: colon specifier is experimental feature (issue #5660) -Warning: pkg-abc.cabal:20:15: colon specifier is experimental feature (issue #5660) Configuring executable 'program' for pkg-abc-0.1.0.0.. Preprocessing executable 'program' for pkg-abc-0.1.0.0.. Building executable 'program' for pkg-abc-0.1.0.0.. diff --git a/cabal-testsuite/PackageTests/MultipleLibraries/T6083Pre/cabal.out b/cabal-testsuite/PackageTests/MultipleLibraries/T6083Pre/cabal.out index 301fd4eadf1..ba78088481b 100644 --- a/cabal-testsuite/PackageTests/MultipleLibraries/T6083Pre/cabal.out +++ b/cabal-testsuite/PackageTests/MultipleLibraries/T6083Pre/cabal.out @@ -4,11 +4,9 @@ Build profile: -w ghc- -O1 In order, the following will be built: - pkg-abc-0.1.0.0 (lib:pkg-def) (first run) - pkg-abc-0.1.0.0 (exe:program) (first run) -Warning: pkg-abc.cabal:19:15: colon specifier is experimental feature (issue #5660) Configuring library 'pkg-def' for pkg-abc-0.1.0.0.. Preprocessing library 'pkg-def' for pkg-abc-0.1.0.0.. Building library 'pkg-def' for pkg-abc-0.1.0.0.. -Warning: pkg-abc.cabal:19:15: colon specifier is experimental feature (issue #5660) Configuring executable 'program' for pkg-abc-0.1.0.0.. Preprocessing executable 'program' for pkg-abc-0.1.0.0.. Building executable 'program' for pkg-abc-0.1.0.0.. diff --git a/cabal-testsuite/PackageTests/MultipleLibraries/T6083PreMixin/cabal.out b/cabal-testsuite/PackageTests/MultipleLibraries/T6083PreMixin/cabal.out index a99e51ecea7..ba78088481b 100644 --- a/cabal-testsuite/PackageTests/MultipleLibraries/T6083PreMixin/cabal.out +++ b/cabal-testsuite/PackageTests/MultipleLibraries/T6083PreMixin/cabal.out @@ -4,11 +4,9 @@ Build profile: -w ghc- -O1 In order, the following will be built: - pkg-abc-0.1.0.0 (lib:pkg-def) (first run) - pkg-abc-0.1.0.0 (exe:program) (first run) -Warning: pkg-abc.cabal:20:15: colon specifier is experimental feature (issue #5660) Configuring library 'pkg-def' for pkg-abc-0.1.0.0.. Preprocessing library 'pkg-def' for pkg-abc-0.1.0.0.. Building library 'pkg-def' for pkg-abc-0.1.0.0.. -Warning: pkg-abc.cabal:20:15: colon specifier is experimental feature (issue #5660) Configuring executable 'program' for pkg-abc-0.1.0.0.. Preprocessing executable 'program' for pkg-abc-0.1.0.0.. Building executable 'program' for pkg-abc-0.1.0.0.. diff --git a/cabal-testsuite/PackageTests/MultipleLibraries/T6894/cabal.out b/cabal-testsuite/PackageTests/MultipleLibraries/T6894/cabal.out index a8ef5791bbb..4f35064dc5e 100644 --- a/cabal-testsuite/PackageTests/MultipleLibraries/T6894/cabal.out +++ b/cabal-testsuite/PackageTests/MultipleLibraries/T6894/cabal.out @@ -4,11 +4,9 @@ Build profile: -w ghc- -O1 In order, the following will be built: - issue-6894 (lib:sublib) (first run) - issue-6894 (lib) (first run) -Warning: issue.cabal:7:30: colon specifier is experimental feature (issue #5660) Configuring library 'sublib' for issue-6894.. Preprocessing library 'sublib' for issue-6894.. Building library 'sublib' for issue-6894.. -Warning: issue.cabal:7:30: colon specifier is experimental feature (issue #5660) Configuring library for issue-6894.. Preprocessing library for issue-6894.. Building library for issue-6894.. diff --git a/cabal-testsuite/PackageTests/MultipleLibraries/T6894/setup.cabal.out b/cabal-testsuite/PackageTests/MultipleLibraries/T6894/setup.cabal.out index a919ff7a59e..536b7d0ddaa 100644 --- a/cabal-testsuite/PackageTests/MultipleLibraries/T6894/setup.cabal.out +++ b/cabal-testsuite/PackageTests/MultipleLibraries/T6894/setup.cabal.out @@ -1,5 +1,4 @@ # Setup configure -Warning: issue.cabal:7:30: colon specifier is experimental feature (issue #5660) Configuring issue-6894... # Setup build Preprocessing library 'sublib' for issue-6894.. diff --git a/cabal-testsuite/PackageTests/MultipleLibraries/T6894/setup.out b/cabal-testsuite/PackageTests/MultipleLibraries/T6894/setup.out index a919ff7a59e..536b7d0ddaa 100644 --- a/cabal-testsuite/PackageTests/MultipleLibraries/T6894/setup.out +++ b/cabal-testsuite/PackageTests/MultipleLibraries/T6894/setup.out @@ -1,5 +1,4 @@ # Setup configure -Warning: issue.cabal:7:30: colon specifier is experimental feature (issue #5660) Configuring issue-6894... # Setup build Preprocessing library 'sublib' for issue-6894.. diff --git a/cabal-testsuite/PackageTests/MultipleLibraries/T7270/cabal.out b/cabal-testsuite/PackageTests/MultipleLibraries/T7270/cabal.out index 8d38ca1ef34..6e1795ddc40 100644 --- a/cabal-testsuite/PackageTests/MultipleLibraries/T7270/cabal.out +++ b/cabal-testsuite/PackageTests/MultipleLibraries/T7270/cabal.out @@ -1,5 +1,4 @@ # Setup configure -Warning: dep.cabal:11:30: visibility is experimental feature (issue #5660) Configuring dep-0.1.0.0... # Setup build Preprocessing library 'sublib' for dep-0.1.0.0.. @@ -13,7 +12,6 @@ Installing library in Registering library 'sublib' for dep-0.1.0.0.. Registering library for dep-0.1.0.0.. # Setup configure -Warning: p.cabal:9:28: colon specifier is experimental feature (issue #5660) Configuring p-0.1.0.0... # Setup build Preprocessing library for p-0.1.0.0..