Support for -fwarn-unused-do-bind and -fwarn-wrong-do-bind, as per #3263
[ghc-hetmet.git] / compiler / typecheck / TcClassDcl.lhs
index cb27a98..4f1f32c 100644 (file)
@@ -224,8 +224,6 @@ tcDefMeth rigid_info clas tyvars theta this_dict binds_in sig_fn prag_fn sel_id
              meth_sig_fn  _ = sig_fn sel_name
              meth_prag_fn _ = prag_fn sel_name
 
-               -- See Note [Silly default-method bind]
-               -- (possibly out of date)
        ; (top_dm_id, bind) <- tcInstanceMethodBody rigid_info
                           clas tyvars [this_dict] theta (mkTyVarTys tyvars)
                           Nothing sel_id
@@ -368,6 +366,7 @@ gives rise to the instance declarations
        instance C 1 where
          op Unit      = ...
 
+
 \begin{code}
 mkGenericDefMethBind :: Class -> [Type] -> Id -> Name -> TcM (LHsBind Name)
 mkGenericDefMethBind clas inst_tys sel_id meth_name
@@ -453,7 +452,7 @@ get_generics decl@(ClassDecl {tcdLName = class_name, tcdMeths = def_methods})
                              group `lengthExceeds` 1]
        get_uniq (tc,_) = getUnique tc
 
-    mapM (addErrTc . dupGenericInsts) bad_groups
+    mapM_ (addErrTc . dupGenericInsts) bad_groups
 
        -- Check that there is an InstInfo for each generic type constructor
     let