polysemy-plugin 0.2.1.0 → 0.2.1.1
raw patch · 8 files changed
+32/−22 lines, 8 filesdep ~basedep ~containersdep ~ghcPVP ok
version bump matches the API change (PVP)
Dependency ranges changed: base, containers, ghc, polysemy, transformers
API changes (from Hackage documentation)
Files
- ChangeLog.md +4/−0
- polysemy-plugin.cabal +15/−13
- src/Polysemy/Plugin/InlineRecursiveCalls.hs +1/−1
- src/Polysemy/Plugin/Phases.hs +4/−0
- test/ExampleSpec.hs +0/−1
- test/InlineRecursiveCallsSpec.hs +6/−2
- test/PluginSpec.hs +2/−4
- test/VDQSpec.hs +0/−1
ChangeLog.md view
@@ -1,5 +1,9 @@ # Changelog for polysemy-plugin +## 0.2.1.1 (2019-06-26)++- Updated the test suite to test against `polysemy-0.5.0.0`+ ## 0.2.1.0 (2019-06-14) - Greatly improved the plugin's ability to unify polymorphic types when running
polysemy-plugin.cabal view
@@ -1,13 +1,13 @@ cabal-version: 1.12 --- This file has been generated from package.yaml by hpack version 0.31.1.+-- This file has been generated from package.yaml by hpack version 0.31.2. -- -- see: https://github.com/sol/hpack ----- hash: e4dc8b1a6c6d69287ad57b504d173944aea70ea24df70dab669ea1f70715c3b0+-- hash: df45f7f2f338b1cac819daf739829c387626de2fb09a1e1c2424004faf90d6b8 name: polysemy-plugin-version: 0.2.1.0+version: 0.2.1.1 synopsis: Disambiguate obvious uses of effects. description: Please see the README on GitHub at <https://github.com/isovector/polysemy/tree/master/polysemy-plugin#readme> category: Polysemy@@ -39,13 +39,13 @@ src default-extensions: DataKinds DeriveFunctor FlexibleContexts GADTs LambdaCase PolyKinds RankNTypes ScopedTypeVariables StandaloneDeriving TypeApplications TypeOperators TypeFamilies UnicodeSyntax build-depends:- base >=4.7 && <5- , containers >=0.6 && <=0.7- , ghc >=8.6.3 && <8.7+ base >=4.9 && <5+ , containers >=0.5 && <0.7+ , ghc >=8.4.4 && <9 , ghc-tcplugins-extra >=0.3 && <0.4 , polysemy >=0.1 , syb >=0.7 && <0.8- , transformers >=0.5.5.0 && <0.6+ , transformers >=0.5.2.0 && <0.6 default-language: Haskell2010 test-suite polysemy-plugin-test@@ -62,17 +62,19 @@ hs-source-dirs: test default-extensions: DataKinds DeriveFunctor FlexibleContexts GADTs LambdaCase PolyKinds RankNTypes ScopedTypeVariables StandaloneDeriving TypeApplications TypeOperators TypeFamilies UnicodeSyntax- ghc-options: -threaded -rtsopts -with-rtsopts=-N -fplugin=Polysemy.Plugin -O2+ ghc-options: -threaded -rtsopts -with-rtsopts=-N -fplugin=Polysemy.Plugin+ build-tool-depends:+ hspec-discover:hspec-discover build-depends:- base >=4.7 && <5- , containers >=0.6 && <=0.7- , ghc >=8.6.3 && <8.7+ base >=4.9 && <5+ , containers >=0.5 && <0.7+ , ghc >=8.4.4 && <9 , ghc-tcplugins-extra >=0.3 && <0.4 , hspec >=2.6.0 && <3 , inspection-testing >=0.4.2 && <0.5- , polysemy >=0.3+ , polysemy >=0.5.0.0 , polysemy-plugin , should-not-typecheck >=2.1.0 && <3 , syb >=0.7 && <0.8- , transformers >=0.5.5.0 && <0.6+ , transformers >=0.5.2.0 && <0.6 default-language: Haskell2010
src/Polysemy/Plugin/InlineRecursiveCalls.hs view
@@ -41,7 +41,7 @@ containsName n e = getAny $ everything- (<>)+ mappend (mkQ (Any False) $ matches n) e
src/Polysemy/Plugin/Phases.hs view
@@ -1,3 +1,5 @@+{-# LANGUAGE CPP #-}+ module Polysemy.Plugin.Phases ( extraPhases ) where@@ -28,7 +30,9 @@ base_mode = SimplMode { sm_phase = error "base_mode" , sm_names = []+#if __GLASGOW_HASKELL__ >= 804 , sm_dflags = dflags+#endif , sm_rules = option Opt_EnableRewriteRules , sm_eta_expand = rules_on , sm_inline = True
test/ExampleSpec.hs view
@@ -1,5 +1,4 @@ {-# LANGUAGE TemplateHaskell #-}-{-# LANGUAGE BlockArguments #-} {-# OPTIONS_GHC -fplugin=Polysemy.Plugin #-} module ExampleSpec where
test/InlineRecursiveCallsSpec.hs view
@@ -1,7 +1,12 @@+{-# LANGUAGE CPP #-} {-# LANGUAGE TemplateHaskell #-}-{-# OPTIONS_GHC -ddump-simpl -dsuppress-coercions -dsuppress-uniques -dsuppress-idinfo #-} +{-# OPTIONS_GHC -O2 #-} +#if __GLASGOW_HASKELL__ < 804+{-# OPTIONS_GHC -fplugin=Test.Inspection.Plugin #-}+#endif+ module InlineRecursiveCallsSpec ( spec ) where@@ -9,7 +14,6 @@ import qualified Control.Monad.Trans.State as S import Data.Tuple import Polysemy.Internal-import Polysemy.Internal.Effect import Polysemy.Internal.Union import Test.Hspec import Test.Inspection
test/PluginSpec.hs view
@@ -1,5 +1,4 @@ {-# LANGUAGE AllowAmbiguousTypes #-}-{-# LANGUAGE BlockArguments #-} {-# LANGUAGE GeneralizedNewtypeDeriving #-} {-# LANGUAGE OverloadedStrings #-} @@ -37,9 +36,8 @@ err :: Member (Error e) r => Sem r Bool err = catch- do- throw undefined- \_ -> pure True+ (throw undefined)+ (\_ -> pure True) errState :: Num s => Members '[Error e, State s] r => Sem r Bool
test/VDQSpec.hs view
@@ -1,5 +1,4 @@ {-# LANGUAGE TemplateHaskell #-}-{-# LANGUAGE BlockArguments #-} {-# OPTIONS_GHC -fplugin=Polysemy.Plugin #-} module VDQSpec where