first-class-families 0.8.0.0 → 0.8.0.1
raw patch · 9 files changed
+29/−39 lines, 9 filesdep −Globdep −doctestdep ~basePVP: major bump suggested
API removals or changes: PVP suggests a major version bump
Dependencies removed: Glob, doctest
Dependency ranges changed: base
API changes (from Hackage documentation)
- Fcf: _If :: IsBool b => (b ~ 'True => r) -> (b ~ 'False => r) -> r
+ Fcf: _If :: IsBool b => (b ~ 'True => r) -> (b ~ 'False => r) -> r
- Fcf: type (-->) = ( 'Match_ :: j -> k -> Match j k)
+ Fcf: type (-->) = ('Match_ :: j -> k -> Match j k)
- Fcf: type Any = ( 'Any_ :: k -> Match j k)
+ Fcf: type Any = ('Any_ :: k -> Match j k)
- Fcf: type Else = ( 'Else_ :: (j -> Exp k) -> Match j k)
+ Fcf: type Else = ('Else_ :: (j -> Exp k) -> Match j k)
- Fcf: type Is = ( 'Is_ :: (j -> Exp Bool) -> k -> Match j k)
+ Fcf: type Is = ('Is_ :: (j -> Exp Bool) -> k -> Match j k)
- Fcf.Class.Foldable: type FoldrDefault_ f y xs = Eval (UnEndo (Eval (FoldMap (Pure1 'Endo <=< Pure1 f) xs)) y)
+ Fcf.Class.Foldable: type FoldrDefault_ f y xs = Eval (UnEndo (Eval (FoldMap (Pure1 'Endo <=< Pure1 f) xs)) y)
- Fcf.Utils: _If :: IsBool b => (b ~ 'True => r) -> (b ~ 'False => r) -> r
+ Fcf.Utils: _If :: IsBool b => (b ~ 'True => r) -> (b ~ 'False => r) -> r
- Fcf.Utils: type (-->) = ( 'Match_ :: j -> k -> Match j k)
+ Fcf.Utils: type (-->) = ('Match_ :: j -> k -> Match j k)
- Fcf.Utils: type Any = ( 'Any_ :: k -> Match j k)
+ Fcf.Utils: type Any = ('Any_ :: k -> Match j k)
- Fcf.Utils: type Else = ( 'Else_ :: (j -> Exp k) -> Match j k)
+ Fcf.Utils: type Else = ('Else_ :: (j -> Exp k) -> Match j k)
- Fcf.Utils: type Is = ( 'Is_ :: (j -> Exp Bool) -> k -> Match j k)
+ Fcf.Utils: type Is = ('Is_ :: (j -> Exp Bool) -> k -> Match j k)
Files
- CHANGELOG.md +5/−0
- first-class-families.cabal +6/−20
- src/Fcf/Class/Bifunctor.hs +1/−0
- src/Fcf/Class/Functor.hs +6/−2
- src/Fcf/Class/Ord.hs +3/−0
- src/Fcf/Data/Bool.hs +3/−0
- src/Fcf/Data/Function.hs +2/−0
- src/Fcf/Data/List.hs +3/−1
- test/doctest.hs +0/−16
CHANGELOG.md view
@@ -1,3 +1,8 @@+# 0.8.0.1++- Bump upper bounds for GHC 9.0+- Update doctests for cabal-docspec+ # 0.8.0.0 - Add modules
first-class-families.cabal view
@@ -1,12 +1,11 @@ name: first-class-families-version: 0.8.0.0+version: 0.8.0.1 synopsis:- First class type families+ First-class type families description:- First class type families,- eval-style defunctionalization+ A library for type-level programming. .- See "Fcf".+ See README. homepage: https://github.com/Lysxia/first-class-families#readme license: MIT license-file: LICENSE@@ -18,7 +17,7 @@ extra-source-files: README.md, CHANGELOG.md cabal-version: >=1.10 tested-with:- GHC == 8.0.2, GHC == 8.2.2, GHC == 8.4.4, GHC == 8.6.5, GHC == 8.8.1+ GHC == 8.0.2, GHC == 8.2.2, GHC == 8.4.4, GHC == 8.6.5, GHC == 8.8.1, GHC == 8.10.1, GHC == 9.0.1 library hs-source-dirs: src@@ -42,7 +41,7 @@ Fcf.Utils build-depends: -- This upper bound is conservative.- base >= 4.9 && < 4.14+ base >= 4.9 && < 4.16 ghc-options: -Wall default-language: Haskell2010 @@ -54,19 +53,6 @@ build-depends: base, first-class-families--test-suite fcf-doctest- type: exitcode-stdio-1.0- hs-source-dirs: test- main-is: doctest.hs- default-language: Haskell2010- if impl(ghc >= 8.6)- build-depends:- base,- doctest,- Glob- else- buildable: False source-repository head type: git
src/Fcf/Class/Bifunctor.hs view
@@ -21,6 +21,7 @@ import Fcf.Combinators (Pure) -- $setup+-- >>> import Fcf.Core (Eval) -- >>> import Fcf.Combinators (Flip) -- >>> import Fcf.Data.Nat (Nat, type (+), type (-)) -- >>> import Fcf.Data.Symbol (Symbol)
src/Fcf/Class/Functor.hs view
@@ -13,6 +13,12 @@ import Fcf.Core (Exp, Eval) +-- $setup+-- >>> :set -XUndecidableInstances -XTypeInType+-- >>> import Fcf.Core (Eval, Exp)+-- >>> import Fcf.Data.Nat+-- >>> import qualified GHC.TypeLits as TL+ -- | Type-level 'fmap' for type-level functors. -- -- Note: this name clashes with 'Data.Map.Lazy.Map' from /containers/.@@ -20,8 +26,6 @@ -- -- === __Example__ ----- >>> import Fcf.Data.Nat--- >>> import qualified GHC.TypeLits as TL -- >>> data AddMul :: Nat -> Nat -> Exp Nat -- >>> type instance Eval (AddMul x y) = (x TL.+ y) TL.* (x TL.+ y) -- >>> :kind! Eval (Map (AddMul 2) '[0, 1, 2, 3, 4])
src/Fcf/Class/Ord.hs view
@@ -29,6 +29,9 @@ import Fcf.Data.Bool (Not) import Fcf.Utils (TyEq) +-- $setup+-- >>> import Fcf.Core (Eval)+ -- | Type-level 'compare' for totally ordered data types. -- -- === __Example__
src/Fcf/Data/Bool.hs view
@@ -19,6 +19,9 @@ import Fcf.Core +-- $setup+-- >>> :set -XTypeFamilies+ -- | N.B.: The order of the two branches is the opposite of "if": -- @UnBool ifFalse ifTrue bool@. --
src/Fcf/Data/Function.hs view
@@ -18,6 +18,8 @@ infixl 1 & -- $setup+-- >>> :set -XTypeFamilies -XDataKinds -XTypeOperators+-- >>> import Fcf.Core -- >>> import Fcf.Combinators (Pure) -- >>> import Fcf.Data.Common (Fst) -- >>> import Fcf.Data.Bool (type (&&), type (||))
src/Fcf/Data/List.hs view
@@ -82,9 +82,11 @@ import Fcf.Utils (If, TyEq) -- $setup--- >>> import Fcf.Core+-- >>> import Fcf.Core (Eval) -- >>> import Fcf.Combinators+-- >>> import Fcf.Class.Monoid () -- >>> import qualified GHC.TypeLits as TL+-- >>> import GHC.TypeLits (Nat) -- | List catenation.
− test/doctest.hs
@@ -1,16 +0,0 @@-import System.FilePath.Glob (glob)-import Test.DocTest--exts :: [String]-exts =- [ "-XDataKinds"- , "-XKindSignatures"- , "-XTypeFamilies"- , "-XTypeOperators"- , "-XUndecidableInstances"- ]--main :: IO ()-main = do- xs <- glob "src/**/*.hs"- doctest (exts ++ xs)