X-Git-Url: http://git.megacz.com/?p=ghc-hetmet.git;a=blobdiff_plain;f=ghc%2Fcompiler%2Ftypecheck%2FTcRnDriver.lhs;h=cbcd892d81090b3b94b1b50de4bcfd2a154e42b0;hp=454f43d677c1573cc598dc6169227c02909e93cc;hb=d191be5da8d2934a5c50bdbc605784d6a9043b6f;hpb=6da2fdc8c83b7f3f400496216f06c9b14ab5efc2 diff --git a/ghc/compiler/typecheck/TcRnDriver.lhs b/ghc/compiler/typecheck/TcRnDriver.lhs index 454f43d..cbcd892 100644 --- a/ghc/compiler/typecheck/TcRnDriver.lhs +++ b/ghc/compiler/typecheck/TcRnDriver.lhs @@ -44,7 +44,7 @@ import TcSimplify ( tcSimplifyTop ) import TcTyClsDecls ( tcTyAndClassDecls ) import LoadIface ( loadOrphanModules ) import RnNames ( importsFromLocalDecls, rnImports, exportsFromAvail, - reportUnusedNames ) + reportUnusedNames, reportDeprecations ) import RnEnv ( lookupSrcOcc_maybe ) import RnSource ( rnSrcDecls, rnTyClDecls, checkModDeprec ) import PprCore ( pprIdRules, pprCoreBindings ) @@ -164,6 +164,13 @@ tcRnModule hsc_env (L loc (HsModule maybe_mod exports traceRn (text "rn3") ; + -- Report the use of any deprecated things + -- We do this before processsing the export list so + -- that we don't bleat about re-exporting a deprecated + -- thing (especially via 'module Foo' export item) + -- Only uses in the body of the module are complained about + reportDeprecations tcg_env ; + -- Process the export list export_avails <- exportsFromAvail (isJust maybe_mod) exports ;