data-fix alternatives and similar packages
Based on the "Data" category.
Alternatively, view data-fix alternatives based on common mentions on social networks and blogs.
-
semantic-source
Parsing, analyzing, and comparing source code across many languages -
lens
Lenses, Folds, and Traversals - Join us on web.libera.chat #haskell-lens -
code-builder
Packages for defining APIs, running them, generating client code and documentation. -
text
Haskell library for space- and time-efficient operations over Unicode text. -
unordered-containers
Efficient hashing-based container types -
compendium-client
Mu (μ) is a purely functional framework for building micro services. -
cassava
A CSV parsing and encoding library optimized for ease of use and high performance -
holmes
A reference library for constraint-solving with propagators and CDCL. -
binary
Efficient, pure binary serialisation using ByteStrings in Haskell. -
primitive
This package provides various primitive memory-related operations. -
resource-pool
A high-performance striped resource pooling implementation for Haskell -
discrimination
Fast linear time sorting and discrimination for a large class of data types -
reflection
Reifies arbitrary Haskell terms into types that can be reflected back into terms -
dependent-sum
Dependent sums and supporting typeclasses for comparing and displaying them -
IORefCAS
A collection of different packages for CAS based data structures. -
dependent-map
Dependently-typed finite maps (partial dependent products) -
text-icu
This package provides the Haskell Data.Text.ICU library, for performing complex manipulation of Unicode text. -
orgmode-parse
Attoparsec parser combinators for parsing org-mode structured text! -
streaming
An optimized general monad transformer for streaming applications, with a simple prelude of functions -
uuid-types
A Haskell library for creating, printing and parsing UUIDs -
scientific
Arbitrary-precision floating-point numbers represented using scientific notation
Clean code begins in your IDE with SonarLint
Do you think we are missing an alternative of data-fix or a related project?
README
data-fix - fixpoint types and recursion schemes
Fixpoint types and recursion schemes. If you define your AST as fixpoint type, you get fold and unfold operations for free.
Fix f = f (Fix f)
Type f
should be a Functor
if you want to use simple
recursion schemes or 'Traversable' if you want to use monadic recursion schemes.
This style allows you to express recursive functions in non-recursive manner.
You can imagine that a non-recursive function holds values of the previous iteration.
Little example:
type List a = Fix (L a)
data L a b = Nil | Cons a b
instance Functor (L a) where
fmap f x = case x of
Nil -> Nil
Cons a b -> Cons a (f b)
length :: List a -> Int
length = cata $ \x -> case x of
Nil -> 0
Cons _ n -> n + 1
sum :: Num a => List a -> a
sum = cata $ \x -> case x of
Nil -> 0
Cons a s -> a + s
Acknowledgements
Thanks for contribution to: Matej Kollar, Herbert Valerio Riedel