Skip to content

Commit fe2ed32

Browse files
committed
Run hlint --default > .hlint.yaml
- Ignore Stack.hs with parse error - Use -XMultilineString in Thread/Stack
1 parent cf10bbd commit fe2ed32

2 files changed

Lines changed: 35 additions & 4 deletions

File tree

.hlint.yaml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
# Warnings currently triggered by your code
2+
- ignore: {name: "Eta reduce"} # 8 hints
3+
- ignore: {name: "Evaluate"} # 4 hints
4+
- ignore: {name: "Fuse mapM/map"} # 1 hint
5+
- ignore: {name: "Move brackets to avoid $"} # 2 hints
6+
- ignore: {name: "Redundant $"} # 4 hints
7+
- ignore: {name: "Redundant <$>"} # 1 hint
8+
- ignore: {name: "Redundant bracket"} # 23 hints
9+
- ignore: {name: "Redundant lambda"} # 2 hints
10+
- ignore: {name: "Redundant return"} # 3 hints
11+
- ignore: {name: "Unused LANGUAGE pragma"} # 33 hints
12+
- ignore: {name: "Use $>"} # 1 hint
13+
- ignore: {name: "Use <$>"} # 4 hints
14+
- ignore: {name: "Use camelCase"} # 4 hints
15+
- ignore: {name: "Use elemIndex"} # 1 hint
16+
- ignore: {name: "Use exitSuccess"} # 2 hints
17+
- ignore: {name: "Use fewer LANGUAGE pragmas"} # 5 hints
18+
- ignore: {name: "Use fewer imports"} # 1 hint
19+
- ignore: {name: "Use handle"} # 1 hint
20+
- ignore: {name: "Use list comprehension"} # 1 hint
21+
- ignore: {name: "Use mapMaybe"} # 2 hints
22+
- ignore: {name: "Use maybeToList"} # 1 hint
23+
- ignore: {name: "Use newtype instead of data"} # 10 hints
24+
- ignore: {name: "Use null"} # 1 hint
25+
- ignore: {name: "Use optional"} # 1 hint
26+
- ignore: {name: "Use or"} # 1 hint
27+
- ignore: {name: "Use print"} # 5 hints
28+
- ignore: {name: "Use record patterns"} # 1 hint
29+
- ignore: {name: "Use uncurry"} # 2 hints
30+
- ignore: {name: "Use unless"} # 2 hints

haskell-debugger/GHC/Debugger/Runtime/Thread/Stack.hs

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
{-# LANGUAGE OrPatterns #-}
22
{-# LANGUAGE MagicHash #-}
3+
{-# LANGUAGE MultilineStrings #-}
34
{-# LANGUAGE QualifiedDo #-}
45
{-# LANGUAGE RecordWildCards #-}
56
{-# LANGUAGE LambdaCase #-}
@@ -181,10 +182,10 @@ bcoBreakPointInfoParser = do
181182
| otherwise = 0 :: Int
182183

183184
let find_ixs_fv = Remote.raw $
184-
"\\x -> let index_at n = GHC.Word.W16# (GHC.Base.indexWord16Array# x (n GHC.Exts.+# " ++ show bRK_FUN_offset ++ "#)) " ++
185-
"in if (index_at 0# Data.Bits..&. 0xFF) == 66{-bci_BRK_FUN-} then \
186-
Just (index_at 1#, index_at 2#, index_at 3#, index_at 4#, index_at 5#) \
187-
else Nothing"
185+
"\\x -> let index_at n = GHC.Word.W16# (GHC.Base.indexWord16Array# x (n GHC.Exts.+# " ++ show bRK_FUN_offset ++ """#))
186+
in if (index_at 0# Data.Bits..&. 0xFF) == 66{-bci_BRK_FUN-} then
187+
Just (index_at 1#, index_at 2#, index_at 3#, index_at 4#, index_at 5#)
188+
else Nothing"""
188189
rs_fv <- expectRight =<< Remote.eval
189190
(find_ixs_fv `Remote.app` Remote.untypedRef instrs_array_fv)
190191

0 commit comments

Comments
 (0)