X-Git-Url: http://git.megacz.com/?p=ghc-hetmet.git;a=blobdiff_plain;f=compiler%2Frename%2FRnSource.lhs;h=b031dd4278ff8b6a92cab6fedeb30e9e719bb53e;hp=71415faefc27f49fc0f4d267618361d89b34c1eb;hb=ad94d40948668032189ad22a0ad741ac1f645f50;hpb=2eb04ca0f8d0ec72b417cddc60672c696b4a3daa diff --git a/compiler/rename/RnSource.lhs b/compiler/rename/RnSource.lhs index 71415fa..b031dd4 100644 --- a/compiler/rename/RnSource.lhs +++ b/compiler/rename/RnSource.lhs @@ -4,6 +4,13 @@ \section[RnSource]{Main pass of renamer} \begin{code} +{-# OPTIONS -w #-} +-- The above warning supression flag is a temporary kludge. +-- While working on this module you are encouraged to remove it and fix +-- any warnings in the module. See +-- http://hackage.haskell.org/trac/ghc/wiki/CodingStyle#Warnings +-- for details + module RnSource ( rnSrcDecls, addTcgDUs, rnTyClDecls, @@ -378,11 +385,11 @@ type variable environment iff -fglasgow-exts \begin{code} extendTyVarEnvForMethodBinds tyvars thing_inside - = doptM Opt_GlasgowExts `thenM` \ opt_GlasgowExts -> - if opt_GlasgowExts then - extendTyVarEnvFVRn (map hsLTyVarName tyvars) thing_inside - else - thing_inside + = do { scoped_tvs <- doptM Opt_ScopedTypeVariables + ; if scoped_tvs then + extendTyVarEnvFVRn (map hsLTyVarName tyvars) thing_inside + else + thing_inside } \end{code} %********************************************************* @@ -770,7 +777,6 @@ rnConDeclDetails doc (RecCon fields) ; new_fields <- mappM (rnField doc) fields ; return (RecCon new_fields) } --- Document comments are renamed to Nothing here rnField doc (ConDeclField name ty haddock_doc) = lookupLocatedTopBndrRn name `thenM` \ new_name -> rnLHsType doc ty `thenM` \ new_ty ->