GHC Proposal #601 proposes a lifecycle for Haskell language extensions and an associated system of compiler warnings. The lifecycle categorizes language extensions as being one of the following:
- An experimental extension, subject to rapid evolution (e.g.
LinearTypes
) - A mature extension, to which changes are not expected (e.g.
DeriveFunctor
) - A deprecated extension, which will be removed from an imminent GHC release
- A legacy extension, which is generally considered to be a design dead-end but that is not scheduled for removal (e.g.
NPlusKPatterns
)
The compiler warnings would (configurably) warn about the use of experimental, legacy, or deprecated extensions.
The Haskell Foundation’s Stability Working Group thinks that this can solve a real need: teams of Haskell developers will be able to more easily understand the status of extensions and express machine-checked policies for CI. Furthermore, if an extension changes categories (e.g. moving from “experimental” to “deprecated”), the new warnings on a compiler update will be a good reminder to check the release notes and see what needs to be done.
The GHC Steering Committee is currently evaluating the proposal. They are interested in feedback from industrial teams - if you’re using Haskell at work, please chime in on the thread, even if your comment is just “Sounds helpful” or “Not relevant to us” (although substantive comments are of course also welcome).