Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
C
Cabal
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Analyze
Contributor analytics
CI/CD analytics
Repository analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Glasgow Haskell Compiler
Packages
Cabal
Commits
24fb7fac
Commit
24fb7fac
authored
14 years ago
by
Ian Lynagh
Browse files
Options
Downloads
Patches
Plain Diff
Generalise deprecatedExtensions
It now works with Extensions rather than KnownExtensions
parent
318f6511
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
Distribution/PackageDescription/Check.hs
+1
-1
1 addition, 1 deletion
Distribution/PackageDescription/Check.hs
Language/Haskell/Extension.hs
+3
-3
3 additions, 3 deletions
Language/Haskell/Extension.hs
with
4 additions
and
4 deletions
Distribution/PackageDescription/Check.hs
+
1
−
1
View file @
24fb7fac
...
...
@@ -423,7 +423,7 @@ checkFields pkg =
deprecatedExtensions
=
nub
$
catMaybes
[
find
((
==
ext
)
.
fst
)
Extension
.
deprecatedExtensions
|
bi
<-
allBuildInfo
pkg
,
EnableExtension
ext
<-
allExtensions
bi
]
,
ext
<-
allExtensions
bi
]
languagesUsedAsExtensions
=
[
name
|
bi
<-
allBuildInfo
pkg
,
UnknownExtension
name
<-
allExtensions
bi
...
...
This diff is collapsed.
Click to expand it.
Language/Haskell/Extension.hs
+
3
−
3
View file @
24fb7fac
...
...
@@ -391,10 +391,10 @@ data KnownExtension =
-- | Extensions that have been deprecated, possibly paired with another
-- extension that replaces it.
--
deprecatedExtensions
::
[(
Known
Extension
,
Maybe
Known
Extension
)]
deprecatedExtensions
::
[(
Extension
,
Maybe
Extension
)]
deprecatedExtensions
=
[
(
RecordPuns
,
Just
NamedFieldPuns
)
,
(
PatternSignatures
,
Just
ScopedTypeVariables
)
[
(
EnableExtension
RecordPuns
,
Just
(
EnableExtension
NamedFieldPuns
)
)
,
(
EnableExtension
PatternSignatures
,
Just
(
EnableExtension
ScopedTypeVariables
)
)
]
-- NOTE: when adding deprecated extensions that have new alternatives
-- we must be careful to make sure that the deprecation messages are
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment