Introduce `Distribution.Compat.Prelude.Internal` + WARNING
This unexposes `Distribution.Compat.Prelude` again, and adds an exposed `.Internal` module which reexports the `.Prelude` module with an attached module-level `WARNING` pragma. This way users are discouraged to use this in `Setup.hs` files as they'd see compile warning like: Foo.hs:19:1-55: warning: [-Wdeprecations] Module ‘Distribution.Compat.Prelude.Internal’: This modules' API is not stable. Use at your own risk, or better yet, use @base-compat@! In `cabal-install` we import the `.Internal` module exactly once, and use -Wno-deprecations to suppress that the warning of that single import.
Showing
- Cabal/Cabal.cabal 2 additions, 1 deletionCabal/Cabal.cabal
- Cabal/Distribution/Compat/Prelude/Internal.hs 14 additions, 0 deletionsCabal/Distribution/Compat/Prelude/Internal.hs
- cabal-install/Distribution/Client/Compat/Prelude.hs 5 additions, 2 deletionscabal-install/Distribution/Client/Compat/Prelude.hs
Please register or sign in to comment