Skip to content

Commit e7df718

Browse files
committed
Strip lines containing "STRIP" from ./striptests
1 parent b044f5b commit e7df718

File tree

4 files changed

+9
-11
lines changed

4 files changed

+9
-11
lines changed

src/ShellCheck/Analytics.hs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ import Data.List
4242
import Data.Maybe
4343
import Data.Ord
4444
import Data.Semigroup
45-
import Debug.Trace
45+
import Debug.Trace -- STRIP
4646
import qualified Data.Map.Strict as Map
4747
import Test.QuickCheck.All (forAllProperties)
4848
import Test.QuickCheck.Test (quickCheckWithResult, stdArgs, maxSuccess)
@@ -1011,8 +1011,8 @@ checkStderrRedirect params redir@(T_Redirecting _ [
10111011

10121012
checkStderrRedirect _ _ = return ()
10131013

1014-
lt x = trace ("Tracing " ++ show x) x
1015-
ltt t = trace ("Tracing " ++ show t)
1014+
lt x = trace ("Tracing " ++ show x) x -- STRIP
1015+
ltt t = trace ("Tracing " ++ show t) -- STRIP
10161016

10171017

10181018
prop_checkSingleQuotedVariables = verify checkSingleQuotedVariables "echo '$foo'"

src/ShellCheck/Formatter/Diff.hs

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,9 +38,6 @@ import System.FilePath
3838

3939
import Test.QuickCheck
4040

41-
import Debug.Trace
42-
ltt x = trace (show x) x
43-
4441
format :: FormatterOptions -> IO Formatter
4542
format options = do
4643
foundIssues <- newIORef False

src/ShellCheck/Parser.hs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ import Data.Functor
3737
import Data.List (isPrefixOf, isInfixOf, isSuffixOf, partition, sortBy, intercalate, nub, find)
3838
import Data.Maybe
3939
import Data.Monoid
40-
import Debug.Trace
40+
import Debug.Trace -- STRIP
4141
import GHC.Exts (sortWith)
4242
import Prelude hiding (readList)
4343
import System.IO
@@ -3372,13 +3372,13 @@ parsesCleanly parser string = runIdentity $ do
33723372

33733373
-- For printf debugging: print the value of an expression
33743374
-- Example: return $ dump $ T_Literal id [c]
3375-
dump :: Show a => a -> a
3376-
dump x = trace (show x) x
3375+
dump :: Show a => a -> a -- STRIP
3376+
dump x = trace (show x) x -- STRIP
33773377

33783378
-- Like above, but print a specific expression:
33793379
-- Example: return $ dumps ("Returning: " ++ [c]) $ T_Literal id [c]
3380-
dumps :: Show x => x -> a -> a
3381-
dumps t = trace (show t)
3380+
dumps :: Show x => x -> a -> a -- STRIP
3381+
dumps t = trace (show t) -- STRIP
33823382

33833383
parseWithNotes parser = do
33843384
item <- parser

striptests

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ detestify() {
2929
state = 0;
3030
}
3131
32+
/STRIP/ { next; }
3233
/LANGUAGE TemplateHaskell/ { next; }
3334
/^import.*Test\./ { next; }
3435

0 commit comments

Comments
 (0)