From 34736bb431aefa956de037af468ca4edc8a8999a Mon Sep 17 00:00:00 2001 From: bjorn Date: Thu, 29 May 2008 08:06:56 +0000 Subject: [PATCH] Only print \n instead of CPU time in putPointE when printing the text message. This avoids printings lots of empty lines in silent mode. --- src-3.0/GF/Infra/UseIO.hs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src-3.0/GF/Infra/UseIO.hs b/src-3.0/GF/Infra/UseIO.hs index 079958b05..5762454d7 100644 --- a/src-3.0/GF/Infra/UseIO.hs +++ b/src-3.0/GF/Infra/UseIO.hs @@ -249,10 +249,10 @@ putPointE v opts msg act = do a <- act >>= ioeIO . evaluate t2 <- ioeIO $ getCPUTime - ioeIO $ putStrLnFlush - (if flag optShowCPUTime opts - then (' ' : show ((t2 - t1) `div` 1000000000) ++ " msec") - else "") + if flag optShowCPUTime opts + then putStrLnE (" " ++ show ((t2 - t1) `div` 1000000000) ++ " msec") + else when (verbAtLeast opts v) $ putStrLnE "" + return a