name: lens category: Data, Lenses version: 1.7 license: BSD3 cabal-version: >= 1.8 license-file: LICENSE author: Edward A. Kmett maintainer: Edward A. Kmett stability: provisional homepage: http://github.com/ekmett/lens/ bug-reports: http://github.com/ekmett/lens/issues copyright: Copyright (C) 2012 Edward A. Kmett synopsis: Lenses, Folds and Traversals description: The combinators in @Control.Lens@ provide a highly generic toolbox for composing families of getters, folds, isomorphisms, traversals, setters and lenses and their indexed variants. . /Lens Families/ . For a longer description of why you should care about lens families, and an overview of why we use 4 parameters a, b, c, and d instead of just 2, see . . Sometimes you won't need the flexibility those extra parameters afford you and you can use . > type Simple f a b = f a a b b . to describe a 'Simple' 'Setter', 'Simple' 'Traversal', 'Simple' 'Lens' or 'Simple' 'Iso'. . /Avoiding Dependencies/ . Note: If you merely want your library to /provide/ lenses you may not have to actually import /any/ lens library at all. For, say, a @'Simple' 'Lens' Bar Foo@, just export a function with the signature: . > foo :: Functor f => (Foo -> f Foo) -> Bar -> f Bar . and then you can compose it with other lenses using nothing more than @(.)@ from the Prelude. . /Deriving Lenses/ . You can derive lenses automatically for many data types using 'makeLenses', and if a container is fully characterized by its lenses, you can use 'Representable' to automatically derive 'Functor', 'Applicative', 'Monad', and 'Distributive'. build-type: Simple tested-with: GHC == 7.4.1 extra-source-files: .travis.yml examples/*.hs test/*.hs README.markdown -- Build examples flag examples default: False manual: True source-repository head type: git location: git://github.com/ekmett/lens.git library build-depends: base >= 4.3 && < 5, containers >= 0.4.2 && < 0.6, mtl >= 2.0.1 && < 2.2, template-haskell >= 2.4 && < 2.8, transformers >= 0.3 && < 0.4 exposed-modules: Control.Exception.Lens Control.Lens Control.Lens.Action Control.Lens.Fold Control.Lens.Getter Control.Lens.Indexed Control.Lens.IndexedGetter Control.Lens.IndexedFold Control.Lens.IndexedLens Control.Lens.IndexedSetter Control.Lens.IndexedTraversal Control.Lens.Internal Control.Lens.Iso Control.Lens.Representable Control.Lens.Setter Control.Lens.TH Control.Lens.Traversal Control.Lens.Type Data.Bits.Lens Data.Complex.Lens Data.Dynamic.Lens Data.Either.Lens Data.List.Lens Data.Pair.Lens Data.IntMap.Lens Data.IntSet.Lens Data.Map.Lens Data.Sequence.Lens Data.Set.Lens Data.Tree.Lens Language.Haskell.TH.Lens -- platform build-depends: array >= 0.3.0.2 && < 0.5 exposed-modules: Data.Array.Lens build-depends: bytestring >= 0.9.1.10 && < 0.10 exposed-modules: Data.ByteString.Lens Data.ByteString.Lazy.Lens build-depends: text >= 0.11.1.5 && < 0.12 exposed-modules: Data.Text.Lens Data.Text.Lazy.Lens build-depends: parallel >= 3.1.0.1 && < 3.3 exposed-modules: Control.Parallel.Strategies.Lens Control.Seq.Lens other-extensions: BangPatterns CPP DeriveDataTypeable FlexibleContexts FlexibleInstances FunctionalDependencies LiberalTypeSynonyms MultiParamTypeClasses Rank2Types RankNTypes TemplateHaskell TypeFamilies TypeOperators UndecidableInstances if (impl(ghc>=7.4)) other-extensions: Trustworthy build-depends: ghc-prim exposed-modules: GHC.Generics.Lens ghc-options: -Wall -fwarn-tabs -O2 -fdicts-cheap -funbox-strict-fields hs-source-dirs: src -- Verify the results of the '>>>'s distributed throughout test-suite doctests type: exitcode-stdio-1.0 main-is: doctests.hs build-depends: base == 4.*, doctest >= 0.8 && <= 0.9 ghc-options: -Wall -Werror -threaded hs-source-dirs: test -- Verify that Template Haskell expansion works test-suite templates type: exitcode-stdio-1.0 main-is: templates.hs build-depends: base == 4.*, lens == 1.7 ghc-options: -Wall -Werror -threaded hs-source-dirs: test -- Verify the properties of lenses with QuickCheck test-suite properties type: exitcode-stdio-1.0 main-is: properties.hs build-depends: base == 4.*, lens == 1.7, QuickCheck >= 2.4 && < 2.6, transformers >= 0.3 && < 0.5 ghc-options: -w -threaded hs-source-dirs: test executable pong if !flag(examples) buildable: False build-depends: base == 4.*, containers >= 0.4.2 && < 0.6, gloss == 1.7.*, lens == 1.7, mtl >= 2.0.1 && < 2.2, random == 1.0.* main-is: Pong.hs hs-source-dirs: examples