extensions 0.1.0.2 → 0.1.0.3
raw patch · 3 files changed
+27/−13 lines, 3 filesdep ~Cabaldep ~basedep ~containersPVP ok
version bump matches the API change (PVP)
Dependency ranges changed: Cabal, base, containers, ghc-boot-th, hedgehog, hspec-hedgehog
API changes (from Hackage documentation)
Files
- CHANGELOG.md +4/−0
- extensions.cabal +8/−7
- src/Extensions/Cabal.hs +15/−6
CHANGELOG.md view
@@ -3,6 +3,10 @@ `extensions` uses [PVP Versioning][1]. The changelog is available [on GitHub][2]. +## 0.1.0.3 — Sep 28, 2024++* Support `Cabal` `3.14` (only)+ ## 0.1.0.2 — Apr 29, 2024 * Add support for GHC-9.8
extensions.cabal view
@@ -1,6 +1,6 @@ cabal-version: 2.4 name: extensions-version: 0.1.0.2+version: 0.1.0.3 synopsis: Parse Haskell Language Extensions description: Parse Haskell Language Extensions. See [README.md](https://github.com/kowainik/extensions#extensions) for more details.@@ -22,6 +22,7 @@ GHC == 9.4.2 GHC == 9.6.3 GHC == 9.8.1+ GHC == 9.10.1 flag executable description: Build the extensions executable@@ -33,7 +34,7 @@ location: https://github.com/kowainik/extensions.git common common-options- build-depends: base >= 4.13.0.0 && < 4.20+ build-depends: base >= 4.13.0.0 && < 4.21 ghc-options: -Wall -Wcompat@@ -93,11 +94,11 @@ -- this causes problems in practice let's -- revisit this decision and come up with -- another approach.- , Cabal ^>= 3.12- , containers ^>= 0.6+ , Cabal ^>= 3.14+ , containers >= 0.6 && < 0.8 , directory ^>= 1.3- , filepath ^>= 1.4- , ghc-boot-th >= 8.8.1 && < 9.9+ , filepath >= 1.4 && < 1.6+ , ghc-boot-th >= 8.8.1 && < 9.11 , parsec ^>= 3.1 , text >= 1.2.3 && < 2.2 @@ -114,7 +115,7 @@ , containers , directory , filepath- , optparse-applicative >= 0.15 && < 0.18+ , optparse-applicative >= 0.15 && < 0.19 , text test-suite extensions-test
src/Extensions/Cabal.hs view
@@ -117,14 +117,14 @@ foreignToExtensions = condTreeToExtensions (const []) foreignLibBuildInfo exeToExtensions :: CondTree var deps Executable -> IO (Map FilePath ParsedExtensions)- exeToExtensions = condTreeToExtensions (\Executable{..} -> [modulePath]) buildInfo+ exeToExtensions = condTreeToExtensions (\Executable{..} -> [getSymbolicPath modulePath]) buildInfo testToExtensions :: CondTree var deps TestSuite -> IO (Map FilePath ParsedExtensions) testToExtensions = condTreeToExtensions testMainPath testBuildInfo where testMainPath :: TestSuite -> [FilePath] testMainPath TestSuite{..} = case testInterface of- TestSuiteExeV10 _ path -> [path]+ TestSuiteExeV10 _ path -> [getSymbolicPath path] TestSuiteLibV09 _ m -> [toModulePath m] TestSuiteUnsupported _ -> [] @@ -133,7 +133,7 @@ where benchMainPath :: Benchmark -> [FilePath] benchMainPath Benchmark{..} = case benchmarkInterface of- BenchmarkExeV10 _ path -> [path]+ BenchmarkExeV10 _ path -> [getSymbolicPath path] BenchmarkUnsupported _ -> [] condTreeToExtensions@@ -399,9 +399,6 @@ Cabal.TypeAbstractions -> Nothing #endif #if __GLASGOW_HASKELL__ >= 910- -- This branch cannot be satisfied yet but we're including it so- -- we don't forget to enable RequiredTypeArguments when it- -- becomes available. Cabal.RequiredTypeArguments -> Just RequiredTypeArguments Cabal.ExtendedLiterals -> Just ExtendedLiterals Cabal.ListTuplePuns -> Just ListTuplePuns@@ -409,6 +406,18 @@ Cabal.RequiredTypeArguments -> Nothing Cabal.ExtendedLiterals -> Nothing Cabal.ListTuplePuns -> Nothing+#endif+#if __GLASGOW_HASKELL__ >= 912+ -- This branch cannot be satisfied yet but we're including it so+ -- we don't forget to enable RequiredTypeArguments when it+ -- becomes available.+ Cabal.NamedDefaults -> Just NamedDefaults+ Cabal.MultilineStrings -> Just MultilineStrings+ Cabal.OrPatterns -> Just OrPatterns+#else+ Cabal.NamedDefaults -> Nothing+ Cabal.MultilineStrings -> Nothing+ Cabal.OrPatterns -> Nothing #endif -- GHC extensions, parsed by both Cabal and GHC, but don't have an Extension constructor Cabal.Safe -> Nothing