-- Hoogle documentation, generated by Haddock -- See Hoogle, http://www.haskell.org/hoogle/ -- | Template haskell conversion of types to a "structural form" built from primitive sum, product, and unit types. -- -- This is an experimental package providing template haskell code to -- convert to and from normal algebraic data types and a representation -- using only haskell's primitive product, sum and unit types: (,), -- Either, and (). -- -- This is something like light-weight Structural Typing. -- -- Please send any comments along. @package shapely-data @version 0.0 module Data.Shapely -- | Generate a Shapely instance and newtype wrapper for the -- referenced types (see above for naming conventions). Usage: -- --
--   $(mkShapely [''Foo])  -- single-quotes reference a TH "Name"
--   
-- -- This requires the TemplateHaskell extension to be enabled. mkShapely :: [Name] -> Q [Dec] -- | A class for types to be converted into a sort of normal form by -- converting its constructors into a combination of Either, -- (,) and (), and back again. class Shapely a b | a -> b, b -> a toShapely :: Shapely a b => a -> b fromShapely :: Shapely a b => b -> a