ghc-tcplugin-api 0.8.1.0 → 0.8.2.0
raw patch · 3 files changed
+20/−3 lines, 3 filesPVP ok
version bump matches the API change (PVP)
API changes (from Hackage documentation)
Files
- changelog.md +6/−1
- ghc-tcplugin-api.cabal +1/−1
- src/GHC/TcPlugin/API/Internal/Shim.hs +13/−1
changelog.md view
@@ -1,6 +1,11 @@+# Version 0.8.2.0 (2022-10-05)++- Bugfix for the GHC 9.0 rewriter plugin compatibility shim:+ fix coercion orientations.+ # Version 0.8.1.0 (2022-10-05) -- Bugfix for the GHC 9.2 (and below) rewriter plugin compatibility shim:+- Bugfix for the GHC 9.2 rewriter plugin compatibility shim: fix coercion orientations. # Version 0.8.0.0 (2022-07-07)
ghc-tcplugin-api.cabal view
@@ -1,6 +1,6 @@ cabal-version: 3.0 name: ghc-tcplugin-api-version: 0.8.1.0+version: 0.8.2.0 synopsis: An API for type-checker plugins. license: BSD-3-Clause build-type: Simple
src/GHC/TcPlugin/API/Internal/Shim.hs view
@@ -551,7 +551,19 @@ forM result downgrade where mkRed :: Maybe (Coercion, Type) -> Maybe Reduction- mkRed = fmap $ \ (co, ty) -> Reduction (mkSymCo co) ty+ mkRed = fmap $ \ (co, ty) ->+ Reduction+ -- On GHC 9.2, lookupFamAppCache and matchFam+ -- use a coercion that goes from right to left.+ -- On GHC 9.0 (and GHC 9.4 and above), the coercions+ -- always go from left to right.+ -- (Recall: this module is only used for GHC 9.2 and below.)+#if MIN_VERSION_ghc(9,2,0)+ (mkSymCo co)+#else+ co+#endif+ ty downgrade :: Reduction -> RewriteM Reduction downgrade redn@(Reduction co xi) = do eq_rel <- getEqRel