summaryrefslogtreecommitdiff
path: root/compiler/utils
diff options
context:
space:
mode:
authorIan Lynagh <igloo@earth.li>2008-03-29 13:57:55 +0000
committerIan Lynagh <igloo@earth.li>2008-03-29 13:57:55 +0000
commit71847273007b8346735f6ec34bfcc8750e2c6ecd (patch)
tree8cc6d38dd713644fa8425f341124263e412a3474 /compiler/utils
parentf555abffd676544cd13d022bf1eb829e63f7aebe (diff)
downloadhaskell-71847273007b8346735f6ec34bfcc8750e2c6ecd.tar.gz
Put debugIsOn in Util, rather than rely on it being CPPed in
Diffstat (limited to 'compiler/utils')
-rw-r--r--compiler/utils/Util.lhs16
1 files changed, 16 insertions, 0 deletions
diff --git a/compiler/utils/Util.lhs b/compiler/utils/Util.lhs
index 59f3b4740d..9537ae1f37 100644
--- a/compiler/utils/Util.lhs
+++ b/compiler/utils/Util.lhs
@@ -6,6 +6,7 @@
\begin{code}
module Util (
+ debugIsOn,
-- general list processing
zipEqual, zipWithEqual, zipWith3Equal, zipWith4Equal,
@@ -107,6 +108,21 @@ infixr 9 `thenCmp`
%************************************************************************
%* *
+\subsection{-DDEBUG}
+%* *
+%************************************************************************
+
+\begin{code}
+debugIsOn :: Bool
+#ifdef DEBUG
+debugIsOn = True
+#else
+debugIsOn = False
+#endif
+\end{code}
+
+%************************************************************************
+%* *
\subsection{A for loop}
%* *
%************************************************************************