Implement -fwarn-dodgy-imports
authorIan Lynagh <igloo@earth.li>
Mon, 16 Jul 2007 22:06:35 +0000 (22:06 +0000)
committerIan Lynagh <igloo@earth.li>
Mon, 16 Jul 2007 22:06:35 +0000 (22:06 +0000)
You used to only be able to enable Opt_WarnDodgyImports with -W or -Wall.
This patch adds the flag to en/disable it by name.
(DodgyImports == importing T(..) when only T is exported).

compiler/main/DynFlags.hs

index d62013a..28943ab 100644 (file)
@@ -1082,6 +1082,7 @@ dynamic_flags = [
 -- these -f<blah> flags can all be reversed with -fno-<blah>
 
 fFlags = [
 -- these -f<blah> flags can all be reversed with -fno-<blah>
 
 fFlags = [
+  ( "warn-dodgy-imports",              Opt_WarnDodgyImports ),
   ( "warn-duplicate-exports",          Opt_WarnDuplicateExports ),
   ( "warn-hi-shadowing",               Opt_WarnHiShadows ),
   ( "warn-implicit-prelude",            Opt_WarnImplicitPrelude ),
   ( "warn-duplicate-exports",          Opt_WarnDuplicateExports ),
   ( "warn-hi-shadowing",               Opt_WarnHiShadows ),
   ( "warn-implicit-prelude",            Opt_WarnImplicitPrelude ),