haskell-src-meta 0.8.13 → 0.8.14
raw patch · 5 files changed
+24/−10 lines, 5 filesdep ~template-haskellPVP ok
version bump matches the API change (PVP)
Dependency ranges changed: template-haskell
API changes (from Hackage documentation)
Files
- ChangeLog +3/−0
- haskell-src-meta.cabal +3/−3
- src/Language/Haskell/Meta/Extensions.hs +7/−0
- src/Language/Haskell/Meta/Parse.hs +7/−7
- src/Language/Haskell/Meta/Syntax/Translate.hs +4/−0
ChangeLog view
@@ -1,3 +1,6 @@+0.8.14+- Support for GHC 9.10 (by Troels Henriksen)+ 0.8.13 - Support for GHC 9.8 (by Vladislav Zavialov)
haskell-src-meta.cabal view
@@ -1,5 +1,5 @@ name: haskell-src-meta-version: 0.8.13+version: 0.8.14 cabal-version: >= 1.10 build-type: Simple license: BSD3@@ -9,7 +9,7 @@ copyright: (c) Matt Morrow maintainer: danburton.email@gmail.com bug-reports: https://github.com/haskell-party/haskell-src-meta/issues-tested-with: GHC == 8.2.2, GHC == 8.4.4, GHC == 8.6.5, GHC == 8.8.4, GHC == 8.10.7, GHC == 9.0.2, GHC == 9.2.2, GHC == 9.4.1, GHC == 9.6.1, GHC == 9.8.1+tested-with: GHC == 8.2.2, GHC == 8.4.4, GHC == 8.6.5, GHC == 8.8.4, GHC == 8.10.7, GHC == 9.0.2, GHC == 9.2.2, GHC == 9.4.1, GHC == 9.6.1, GHC == 9.8.1, GHC == 9.10.1 synopsis: Parse source to template-haskell abstract syntax. description: The translation from haskell-src-exts abstract syntax to template-haskell abstract syntax isn't 100% complete yet.@@ -22,7 +22,7 @@ haskell-src-exts >= 1.21 && < 1.24, pretty >= 1.0 && < 1.2, syb >= 0.1 && < 0.8,- template-haskell >= 2.12 && < 2.22,+ template-haskell >= 2.12 && < 2.23, th-orphans >= 0.12 && < 0.14 hs-source-dirs: src
src/Language/Haskell/Meta/Extensions.hs view
@@ -367,6 +367,13 @@ TH.ExtendedLiterals -> Nothing #endif +-- 2.22.0 ---------------------------------------++#if MIN_VERSION_template_haskell(2,22,0)+ TH.RequiredTypeArguments -> Nothing+ TH.ListTuplePuns -> Nothing+#endif+ -- NB: when adding a case here, you may also need to update `toExtension`
src/Language/Haskell/Meta/Parse.hs view
@@ -43,20 +43,20 @@ -- * template-haskell parsePat :: String -> Either String Pat-parsePat = either Left (Right . toPat) . parseHsPat+parsePat = fmap toPat . parseHsPat parseExp :: String -> Either String Exp-parseExp = either Left (Right . toExp) . parseHsExp+parseExp = fmap toExp . parseHsExp parseType :: String -> Either String Type-parseType = either Left (Right . toType) . parseHsType+parseType = fmap toType . parseHsType parseDecs :: String -> Either String [Dec]-parseDecs = either Left (Right . toDecs) . parseHsDecls+parseDecs = fmap toDecs . parseHsDecls -- | @since 0.8.2 parseDecsWithMode :: ParseMode -> String -> Either String [Dec]-parseDecsWithMode parseMode = either Left (Right . toDecs)+parseDecsWithMode parseMode = fmap toDecs . parseHsDeclsWithMode parseMode -----------------------------------------------------------------------------@@ -93,12 +93,12 @@ parseHsModule = parseResultToEither . parseModuleWithMode myDefaultParseMode parseHsDecls :: String -> Either String [Hs.Decl Hs.SrcSpanInfo]-parseHsDecls = either Left (Right . moduleDecls)+parseHsDecls = fmap moduleDecls . parseResultToEither . parseModuleWithMode myDefaultParseMode -- | @since 0.8.2 parseHsDeclsWithMode :: ParseMode -> String -> Either String [Hs.Decl Hs.SrcSpanInfo]-parseHsDeclsWithMode parseMode = either Left (Right . moduleDecls)+parseHsDeclsWithMode parseMode = fmap moduleDecls . parseResultToEither . parseModuleWithMode parseMode
src/Language/Haskell/Meta/Syntax/Translate.hs view
@@ -798,7 +798,11 @@ toDecs (Exts.InfixDecl l assoc Nothing ops) = toDecs (Exts.InfixDecl l assoc (Just 9) ops) toDecs (Exts.InfixDecl _ assoc (Just fixity) ops) =+#if MIN_VERSION_template_haskell(2,22,0)+ map (\op -> TH.InfixD (TH.Fixity fixity dir) TH.NoNamespaceSpecifier (toName op)) ops+#else map (\op -> TH.InfixD (TH.Fixity fixity dir) (toName op)) ops+#endif where dir = case assoc of Exts.AssocNone _ -> TH.InfixN