[commit: ghc] master: compiler/specialise: shut match_co up a bit (f5b43ce)

git at git.haskell.org git at git.haskell.org
Mon Jun 1 08:45:23 UTC 2015


Repository : ssh://git@git.haskell.org/ghc

On branch  : master
Link       : http://ghc.haskell.org/trac/ghc/changeset/f5b43ce177e40a34afb1913bc0ec866185ed95d7/ghc

>---------------------------------------------------------------

commit f5b43ce177e40a34afb1913bc0ec866185ed95d7
Author: Austin Seipp <austin at well-typed.com>
Date:   Mon Jun 1 03:45:11 2015 -0500

    compiler/specialise: shut match_co up a bit
    
    This stray pprTrace is quite annoying and makes our build logs a bit
    bigger (hundreds of lines of occurrences), so we should probably just
    get rid of it. Kept under DEBUG for future brave hackers.
    
    Signed-off-by: Austin Seipp <austin at well-typed.com>
    
    Reviewed By: thomie, nomeata
    
    Differential Revision: https://phabricator.haskell.org/D934


>---------------------------------------------------------------

f5b43ce177e40a34afb1913bc0ec866185ed95d7
 compiler/specialise/Rules.hs | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

diff --git a/compiler/specialise/Rules.hs b/compiler/specialise/Rules.hs
index e6e5359..3601253 100644
--- a/compiler/specialise/Rules.hs
+++ b/compiler/specialise/Rules.hs
@@ -733,9 +733,13 @@ match_co renv subst (TyConAppCo r1 tc1 cos1) co2
          | r1 == r2 && tc1 == tc2
          -> match_cos renv subst cos1 cos2
        _ -> Nothing
-match_co _ _ co1 co2
-  = pprTrace "match_co: needs more cases" (ppr co1 $$ ppr co2) Nothing
+match_co _ _ _co1 _co2
     -- Currently just deals with CoVarCo, TyConAppCo and Refl
+#ifdef DEBUG
+  = pprTrace "match_co: needs more cases" (ppr _co1 $$ ppr _co2) Nothing
+#else
+  = Nothing
+#endif
 
 match_cos :: RuleMatchEnv
          -> RuleSubst



More information about the ghc-commits mailing list