From 4e9b6d7bf46682265747f5f162128bc3db213513 Mon Sep 17 00:00:00 2001 From: simonpj Date: Fri, 6 May 2005 11:06:14 +0000 Subject: [PATCH] [project @ 2005-05-06 11:06:14 by simonpj] Rule overlap message should be only in ifdef DEBUG --- ghc/compiler/specialise/Rules.lhs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ghc/compiler/specialise/Rules.lhs b/ghc/compiler/specialise/Rules.lhs index 6901821..4728920 100644 --- a/ghc/compiler/specialise/Rules.lhs +++ b/ghc/compiler/specialise/Rules.lhs @@ -232,11 +232,15 @@ findBest target (rule,ans) [] = (rule,ans) findBest target (rule1,ans1) ((rule2,ans2):prs) | rule1 `isMoreSpecific` rule2 = findBest target (rule1,ans1) prs | rule2 `isMoreSpecific` rule1 = findBest target (rule1,ans1) prs +#ifdef DEBUG | otherwise = pprTrace "Rules.findBest: rule overlap (Rule 1 wins)" (vcat [ptext SLIT("Expression to match:") <+> ppr fn <+> sep (map ppr args), ptext SLIT("Rule 1:") <+> ppr rule1, ptext SLIT("Rule 2:") <+> ppr rule2]) $ findBest target (rule1,ans1) prs +#else + | otherwise = findBest target (rule1,ans1) prs +#endif where (fn,args) = target -- 1.7.10.4