Permalink
Browse files

Removed the `complex` lens, it uses the wrong naming convention and i…

…s now subsumed by `each`.
  • Loading branch information...
1 parent 5806adc commit 005419677b472cc6e737a0b53d7901ad12a3054e @ekmett committed Jan 21, 2013
Showing with 0 additions and 21 deletions.
  1. +0 −21 src/Data/Complex/Lens.hs
View
@@ -22,7 +22,6 @@ module Data.Complex.Lens
, _magnitude
, _phase
, _conjugate
- , complex
) where
import Control.Applicative
@@ -132,23 +131,3 @@ _phase f c = setPhase <$> f theta
_conjugate :: RealFloat a => Iso' (Complex a) (Complex a)
_conjugate = iso conjugate conjugate
{-# INLINE _conjugate #-}
-
--- | Traverse both the 'realPart' and the 'imagPart' of a 'Complex' number.
---
--- >>> a :+ b & complex .~ c
--- c :+ c
---
--- >>> a :+ b & complex *~ 2
--- a * 2 :+ b * 2
---
--- >>> sumOf complex (a :+ b)
--- 0 + a + b
---
--- @'complex' :: 'Applicative' f => (a -> f b) -> 'Complex' a -> f ('Complex' b)@
-#if MIN_VERSION_base(4,4,0)
-complex :: Traversal (Complex a) (Complex b) a b
-#else
-complex :: (RealFloat a, RealFloat b) => Traversal (Complex a) (Complex b) a b
-#endif
-complex f (a :+ b) = (:+) <$> f a <*> f b
-{-# INLINE complex #-}

0 comments on commit 0054196

Please sign in to comment.