summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon Peyton Jones <simonpj@microsoft.com>2012-03-27 13:43:18 +0100
committerSimon Peyton Jones <simonpj@microsoft.com>2012-03-27 13:44:35 +0100
commit5673173de699d556ef7f51a1b558bd1ec676fd52 (patch)
tree6c10a4f0b57cda941eae87b433f2dc54111e7bef
parent6403540416c22421516c91b12df630d4dce17686 (diff)
parent673b1bec23ae62a5bad7a4761409bc6b0e2c314c (diff)
downloadhaskell-5673173de699d556ef7f51a1b558bd1ec676fd52.tar.gz
Merge with HEAD
-rw-r--r--compiler/parser/RdrHsSyn.lhs16
1 files changed, 2 insertions, 14 deletions
diff --git a/compiler/parser/RdrHsSyn.lhs b/compiler/parser/RdrHsSyn.lhs
index 8c4ff3c3b8..91bab6c3fb 100644
--- a/compiler/parser/RdrHsSyn.lhs
+++ b/compiler/parser/RdrHsSyn.lhs
@@ -6,7 +6,6 @@ Functions over HsSyn specialised to RdrName.
\begin{code}
module RdrHsSyn (
extractHsTyRdrTyVars, extractHsTysRdrTyVars,
- extractGenericPatTyVars,
mkHsOpApp,
mkHsIntegral, mkHsFractional, mkHsIsString,
@@ -75,7 +74,7 @@ import PrelNames ( forall_tv_RDR )
import DynFlags
import SrcLoc
import OrdList ( OrdList, fromOL )
-import Bag ( Bag, emptyBag, consBag, foldrBag )
+import Bag ( Bag, emptyBag, consBag )
import Outputable
import FastString
import Maybes
@@ -83,7 +82,7 @@ import Util ( filterOut )
import Control.Applicative ((<$>))
import Control.Monad
import Text.ParserCombinators.ReadP as ReadP
-import Data.List ( nub, nubBy )
+import Data.List ( nub )
import Data.Char
#include "HsVersions.h"
@@ -147,17 +146,6 @@ extract_lty (L _ ty) acc
extract_tv :: RdrName -> [RdrName] -> [RdrName]
extract_tv tv acc | isRdrTyVar tv = tv : acc
| otherwise = acc
-
-extractGenericPatTyVars :: LHsBinds RdrName -> [Located RdrName]
--- Get the type variables out of the type patterns in a bunch of
--- possibly-generic bindings in a class declaration
-extractGenericPatTyVars binds
- = nubBy eqLocated (foldrBag get [] binds)
- where
- get (L _ (FunBind { fun_matches = MatchGroup ms _ })) acc = foldr (get_m.unLoc) acc ms
- get _ acc = acc
-
- get_m _ acc = acc
\end{code}