293 lines
		
	
	
	
		
			8.5 KiB
			
		
	
	
	
		
			Diff
		
	
	
	
	
	
			
		
		
	
	
			293 lines
		
	
	
	
		
			8.5 KiB
			
		
	
	
	
		
			Diff
		
	
	
	
	
	
From bbb49942123f06a36b170966e445692297f71d26 Mon Sep 17 00:00:00 2001
 | 
						|
From: Joey Hess <joey@kitenet.net>
 | 
						|
Date: Thu, 18 Apr 2013 19:14:30 -0400
 | 
						|
Subject: [PATCH] build without TH
 | 
						|
 | 
						|
---
 | 
						|
 lens.cabal                          | 13 +------------
 | 
						|
 src/Control/Exception/Lens.hs       |  2 +-
 | 
						|
 src/Control/Lens.hs                 |  6 +++---
 | 
						|
 src/Control/Lens/Equality.hs        |  4 ++--
 | 
						|
 src/Control/Lens/Fold.hs            |  6 +++---
 | 
						|
 src/Control/Lens/Internal.hs        |  2 +-
 | 
						|
 src/Control/Lens/Internal/Zipper.hs |  2 +-
 | 
						|
 src/Control/Lens/Iso.hs             |  2 --
 | 
						|
 src/Control/Lens/Lens.hs            |  2 +-
 | 
						|
 src/Control/Lens/Operators.hs       |  2 +-
 | 
						|
 src/Control/Lens/Plated.hs          |  2 +-
 | 
						|
 src/Control/Lens/Setter.hs          |  2 --
 | 
						|
 src/Control/Lens/TH.hs              |  2 +-
 | 
						|
 src/Data/Data/Lens.hs               |  6 +++---
 | 
						|
 14 files changed, 19 insertions(+), 34 deletions(-)
 | 
						|
 | 
						|
diff --git a/lens.cabal b/lens.cabal
 | 
						|
index a06b3ce..a654b3d 100644
 | 
						|
--- a/lens.cabal
 | 
						|
+++ b/lens.cabal
 | 
						|
@@ -10,7 +10,7 @@ stability:     provisional
 | 
						|
 homepage:      http://github.com/ekmett/lens/
 | 
						|
 bug-reports:   http://github.com/ekmett/lens/issues
 | 
						|
 copyright:     Copyright (C) 2012-2013 Edward A. Kmett
 | 
						|
-build-type:    Custom
 | 
						|
+build-type:    Simple
 | 
						|
 tested-with:   GHC == 7.0.4, GHC == 7.4.1, GHC == 7.4.2, GHC == 7.6.1, GHC == 7.7.20121213, GHC == 7.7.20130117
 | 
						|
 synopsis:      Lenses, Folds and Traversals
 | 
						|
 description:
 | 
						|
@@ -171,7 +171,6 @@ library
 | 
						|
     containers                >= 0.4.0    && < 0.6,
 | 
						|
     distributive              >= 0.3      && < 1,
 | 
						|
     filepath                  >= 1.2.0.0  && < 1.4,
 | 
						|
-    generic-deriving          == 1.4.*,
 | 
						|
     ghc-prim,
 | 
						|
     hashable                  >= 1.1.2.3  && < 1.3,
 | 
						|
     MonadCatchIO-transformers >= 0.3      && < 0.4,
 | 
						|
@@ -233,14 +232,12 @@ library
 | 
						|
     Control.Lens.Review
 | 
						|
     Control.Lens.Setter
 | 
						|
     Control.Lens.Simple
 | 
						|
-    Control.Lens.TH
 | 
						|
     Control.Lens.Traversal
 | 
						|
     Control.Lens.Tuple
 | 
						|
     Control.Lens.Type
 | 
						|
     Control.Lens.Wrapped
 | 
						|
     Control.Lens.Zipper
 | 
						|
     Control.Lens.Zoom
 | 
						|
-    Control.Monad.Error.Lens
 | 
						|
     Control.Parallel.Strategies.Lens
 | 
						|
     Control.Seq.Lens
 | 
						|
     Data.Array.Lens
 | 
						|
@@ -264,12 +261,8 @@ library
 | 
						|
     Data.Typeable.Lens
 | 
						|
     Data.Vector.Lens
 | 
						|
     Data.Vector.Generic.Lens
 | 
						|
-    Generics.Deriving.Lens
 | 
						|
-    GHC.Generics.Lens
 | 
						|
     System.Exit.Lens
 | 
						|
     System.FilePath.Lens
 | 
						|
-    System.IO.Error.Lens
 | 
						|
-    Language.Haskell.TH.Lens
 | 
						|
     Numeric.Lens
 | 
						|
 
 | 
						|
   if flag(safe)
 | 
						|
@@ -368,7 +361,6 @@ test-suite doctests
 | 
						|
       deepseq,
 | 
						|
       doctest        >= 0.9.1,
 | 
						|
       filepath,
 | 
						|
-      generic-deriving,
 | 
						|
       mtl,
 | 
						|
       nats,
 | 
						|
       parallel,
 | 
						|
@@ -394,7 +386,6 @@ benchmark plated
 | 
						|
     comonad,
 | 
						|
     criterion,
 | 
						|
     deepseq,
 | 
						|
-    generic-deriving,
 | 
						|
     lens,
 | 
						|
     transformers
 | 
						|
 
 | 
						|
@@ -429,7 +420,6 @@ benchmark unsafe
 | 
						|
     comonads-fd,
 | 
						|
     criterion,
 | 
						|
     deepseq,
 | 
						|
-    generic-deriving,
 | 
						|
     lens,
 | 
						|
     transformers
 | 
						|
 
 | 
						|
@@ -446,6 +436,5 @@ benchmark zipper
 | 
						|
     comonads-fd,
 | 
						|
     criterion,
 | 
						|
     deepseq,
 | 
						|
-    generic-deriving,
 | 
						|
     lens,
 | 
						|
     transformers
 | 
						|
diff --git a/src/Control/Exception/Lens.hs b/src/Control/Exception/Lens.hs
 | 
						|
index 5c26d4e..9909132 100644
 | 
						|
--- a/src/Control/Exception/Lens.hs
 | 
						|
+++ b/src/Control/Exception/Lens.hs
 | 
						|
@@ -112,7 +112,7 @@ import Prelude
 | 
						|
   ,  Maybe(..), Either(..), Functor(..), String, IO
 | 
						|
   )
 | 
						|
 
 | 
						|
-{-# ANN module "HLint: ignore Use Control.Exception.catch" #-}
 | 
						|
+
 | 
						|
 
 | 
						|
 -- $setup
 | 
						|
 -- >>> :set -XNoOverloadedStrings
 | 
						|
diff --git a/src/Control/Lens.hs b/src/Control/Lens.hs
 | 
						|
index 8481e44..74700ae 100644
 | 
						|
--- a/src/Control/Lens.hs
 | 
						|
+++ b/src/Control/Lens.hs
 | 
						|
@@ -59,7 +59,7 @@ module Control.Lens
 | 
						|
   , module Control.Lens.Review
 | 
						|
   , module Control.Lens.Setter
 | 
						|
   , module Control.Lens.Simple
 | 
						|
-#ifndef DISABLE_TEMPLATE_HASKELL
 | 
						|
+#if 0
 | 
						|
   , module Control.Lens.TH
 | 
						|
 #endif
 | 
						|
   , module Control.Lens.Traversal
 | 
						|
@@ -89,7 +89,7 @@ import Control.Lens.Reified
 | 
						|
 import Control.Lens.Review
 | 
						|
 import Control.Lens.Setter
 | 
						|
 import Control.Lens.Simple
 | 
						|
-#ifndef DISABLE_TEMPLATE_HASKELL
 | 
						|
+#if 0
 | 
						|
 import Control.Lens.TH
 | 
						|
 #endif
 | 
						|
 import Control.Lens.Traversal
 | 
						|
@@ -99,4 +99,4 @@ import Control.Lens.Wrapped
 | 
						|
 import Control.Lens.Zipper
 | 
						|
 import Control.Lens.Zoom
 | 
						|
 
 | 
						|
-{-# ANN module "HLint: ignore Use import/export shortcut" #-}
 | 
						|
+
 | 
						|
diff --git a/src/Control/Lens/Equality.hs b/src/Control/Lens/Equality.hs
 | 
						|
index 982c2d7..3a3fe1a 100644
 | 
						|
--- a/src/Control/Lens/Equality.hs
 | 
						|
+++ b/src/Control/Lens/Equality.hs
 | 
						|
@@ -28,8 +28,8 @@ module Control.Lens.Equality
 | 
						|
 import Control.Lens.Internal.Setter
 | 
						|
 import Control.Lens.Type
 | 
						|
 
 | 
						|
-{-# ANN module "HLint: ignore Use id" #-}
 | 
						|
-{-# ANN module "HLint: ignore Eta reduce" #-}
 | 
						|
+
 | 
						|
+
 | 
						|
 
 | 
						|
 -- $setup
 | 
						|
 -- >>> import Control.Lens
 | 
						|
diff --git a/src/Control/Lens/Fold.hs b/src/Control/Lens/Fold.hs
 | 
						|
index ae5100d..467eb37 100644
 | 
						|
--- a/src/Control/Lens/Fold.hs
 | 
						|
+++ b/src/Control/Lens/Fold.hs
 | 
						|
@@ -161,9 +161,9 @@ import Data.Traversable
 | 
						|
 -- >>> let g :: Expr -> Expr; g = Debug.SimpleReflect.Vars.g
 | 
						|
 -- >>> let timingOut :: NFData a => a -> IO a; timingOut = fmap (fromMaybe (error "timeout")) . timeout (5*10^6) . evaluate . force
 | 
						|
 
 | 
						|
-{-# ANN module "HLint: ignore Eta reduce" #-}
 | 
						|
-{-# ANN module "HLint: ignore Use camelCase" #-}
 | 
						|
-{-# ANN module "HLint: ignore Use curry" #-}
 | 
						|
+
 | 
						|
+
 | 
						|
+
 | 
						|
 
 | 
						|
 infixl 8 ^.., ^?, ^?!, ^@.., ^@?, ^@?!
 | 
						|
 
 | 
						|
diff --git a/src/Control/Lens/Internal.hs b/src/Control/Lens/Internal.hs
 | 
						|
index 295662e..539642d 100644
 | 
						|
--- a/src/Control/Lens/Internal.hs
 | 
						|
+++ b/src/Control/Lens/Internal.hs
 | 
						|
@@ -43,4 +43,4 @@ import Control.Lens.Internal.Review
 | 
						|
 import Control.Lens.Internal.Setter
 | 
						|
 import Control.Lens.Internal.Zoom
 | 
						|
 
 | 
						|
-{-# ANN module "HLint: ignore Use import/export shortcut" #-}
 | 
						|
+
 | 
						|
diff --git a/src/Control/Lens/Internal/Zipper.hs b/src/Control/Lens/Internal/Zipper.hs
 | 
						|
index 95875b7..76060be 100644
 | 
						|
--- a/src/Control/Lens/Internal/Zipper.hs
 | 
						|
+++ b/src/Control/Lens/Internal/Zipper.hs
 | 
						|
@@ -53,7 +53,7 @@ import Data.Profunctor.Unsafe
 | 
						|
 -- >>> import Control.Lens
 | 
						|
 -- >>> import Data.Char
 | 
						|
 
 | 
						|
-{-# ANN module "HLint: ignore Use foldl" #-}
 | 
						|
+
 | 
						|
 
 | 
						|
 ------------------------------------------------------------------------------
 | 
						|
 -- * Jacket
 | 
						|
diff --git a/src/Control/Lens/Iso.hs b/src/Control/Lens/Iso.hs
 | 
						|
index 62d40ef..235511a 100644
 | 
						|
--- a/src/Control/Lens/Iso.hs
 | 
						|
+++ b/src/Control/Lens/Iso.hs
 | 
						|
@@ -70,8 +70,6 @@ import Data.Profunctor.Unsafe
 | 
						|
 import Unsafe.Coerce
 | 
						|
 #endif
 | 
						|
 
 | 
						|
-{-# ANN module "HLint: ignore Use on" #-}
 | 
						|
-
 | 
						|
 -- $setup
 | 
						|
 -- >>> :set -XNoOverloadedStrings
 | 
						|
 -- >>> import Control.Lens
 | 
						|
diff --git a/src/Control/Lens/Lens.hs b/src/Control/Lens/Lens.hs
 | 
						|
index ff2a45f..5401ec4 100644
 | 
						|
--- a/src/Control/Lens/Lens.hs
 | 
						|
+++ b/src/Control/Lens/Lens.hs
 | 
						|
@@ -120,7 +120,7 @@ import Data.Profunctor
 | 
						|
 import Data.Profunctor.Rep
 | 
						|
 import Data.Profunctor.Unsafe
 | 
						|
 
 | 
						|
-{-# ANN module "HLint: ignore Use ***" #-}
 | 
						|
+
 | 
						|
 
 | 
						|
 -- $setup
 | 
						|
 -- >>> :set -XNoOverloadedStrings
 | 
						|
diff --git a/src/Control/Lens/Operators.hs b/src/Control/Lens/Operators.hs
 | 
						|
index d88cb49..fa7b37e 100644
 | 
						|
--- a/src/Control/Lens/Operators.hs
 | 
						|
+++ b/src/Control/Lens/Operators.hs
 | 
						|
@@ -107,4 +107,4 @@ import Control.Lens.Review
 | 
						|
 import Control.Lens.Setter
 | 
						|
 import Control.Lens.Zipper
 | 
						|
 
 | 
						|
-{-# ANN module "HLint: ignore Use import/export shortcut" #-}
 | 
						|
+
 | 
						|
diff --git a/src/Control/Lens/Plated.hs b/src/Control/Lens/Plated.hs
 | 
						|
index 07d9212..27070c0 100644
 | 
						|
--- a/src/Control/Lens/Plated.hs
 | 
						|
+++ b/src/Control/Lens/Plated.hs
 | 
						|
@@ -95,7 +95,7 @@ import           Data.Data.Lens
 | 
						|
 import           Data.Monoid
 | 
						|
 import           Data.Tree
 | 
						|
 
 | 
						|
-{-# ANN module "HLint: ignore Reduce duplication" #-}
 | 
						|
+
 | 
						|
 
 | 
						|
 -- | A 'Plated' type is one where we know how to extract its immediate self-similar children.
 | 
						|
 --
 | 
						|
diff --git a/src/Control/Lens/Setter.hs b/src/Control/Lens/Setter.hs
 | 
						|
index 2acbfa6..4a12c6b 100644
 | 
						|
--- a/src/Control/Lens/Setter.hs
 | 
						|
+++ b/src/Control/Lens/Setter.hs
 | 
						|
@@ -87,8 +87,6 @@ import Data.Profunctor
 | 
						|
 import Data.Profunctor.Rep
 | 
						|
 import Data.Profunctor.Unsafe
 | 
						|
 
 | 
						|
-{-# ANN module "HLint: ignore Avoid lambda" #-}
 | 
						|
-
 | 
						|
 -- $setup
 | 
						|
 -- >>> import Control.Lens
 | 
						|
 -- >>> import Control.Monad.State
 | 
						|
diff --git a/src/Control/Lens/TH.hs b/src/Control/Lens/TH.hs
 | 
						|
index fbf4adb..ee723d7 100644
 | 
						|
--- a/src/Control/Lens/TH.hs
 | 
						|
+++ b/src/Control/Lens/TH.hs
 | 
						|
@@ -87,7 +87,7 @@ import Language.Haskell.TH
 | 
						|
 import Language.Haskell.TH.Syntax
 | 
						|
 import Language.Haskell.TH.Lens
 | 
						|
 
 | 
						|
-{-# ANN module "HLint: ignore Use foldl" #-}
 | 
						|
+
 | 
						|
 
 | 
						|
 -- | Flags for 'Lens' construction
 | 
						|
 data LensFlag
 | 
						|
diff --git a/src/Data/Data/Lens.hs b/src/Data/Data/Lens.hs
 | 
						|
index cf1e7c9..b39dacf 100644
 | 
						|
--- a/src/Data/Data/Lens.hs
 | 
						|
+++ b/src/Data/Data/Lens.hs
 | 
						|
@@ -65,9 +65,9 @@ import           Data.Monoid
 | 
						|
 import           GHC.Exts (realWorld#)
 | 
						|
 #endif
 | 
						|
 
 | 
						|
-{-# ANN module "HLint: ignore Eta reduce" #-}
 | 
						|
-{-# ANN module "HLint: ignore Use foldl" #-}
 | 
						|
-{-# ANN module "HLint: ignore Reduce duplication" #-}
 | 
						|
+
 | 
						|
+
 | 
						|
+
 | 
						|
 
 | 
						|
 -- $setup
 | 
						|
 -- >>> :set -XNoOverloadedStrings
 | 
						|
-- 
 | 
						|
1.8.2.rc3
 | 
						|
 |