Skip to content

Commit 619098e

Browse files
dylan-thinnesJaro Reinders
authored andcommitted
Fixes for stylish-haskell
stylish-haskell does not handle CPP pragmas very well, is this a regression?
1 parent 0a2174d commit 619098e

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

ghcide/test/exe/FuzzySearch.hs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ referenceImplementation ::
8787
(t -> s) ->
8888
-- | The original value, rendered string and score.
8989
Maybe (Fuzzy t s)
90-
referenceImplementation pattern t pre post extract =
90+
referenceImplementation pat t pre post extract =
9191
if null pat then Just (Fuzzy t result totalScore) else Nothing
9292
where
9393
null :: (T.TextualMonoid s) => s -> Bool
@@ -118,7 +118,7 @@ referenceImplementation pattern t pre post extract =
118118
( 0,
119119
1, -- matching at the start gives a bonus (cur = 1)
120120
mempty,
121-
pattern,
121+
pat,
122122
True
123123
)
124124
s

plugins/hls-refactor-plugin/src/Development/IDE/Plugin/CodeAction.hs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,10 +65,10 @@ import Development.IDE.Plugin.Plugins.FillHole (suggestFillH
6565
import Development.IDE.Plugin.Plugins.FillTypeWildcard (suggestFillTypeWildcard)
6666
import Development.IDE.Plugin.Plugins.ImportUtils
6767
import Development.IDE.Plugin.TypeLenses (suggestSignature)
68+
import Development.IDE.Types.Diagnostics
6869
import Development.IDE.Types.Exports
6970
import Development.IDE.Types.Location
7071
import Development.IDE.Types.Options
71-
import Development.IDE.Types.Diagnostics
7272
import GHC (AddEpAnn (AddEpAnn),
7373
AnnsModule (am_main),
7474
DeltaPos (..),
@@ -2008,6 +2008,7 @@ smallerRangesForBindingExport lies b =
20082008
| T.unpack (printOutputable thing) == b' = []
20092009
| otherwise =
20102010
[ locA l' | L l' x <- inners, T.unpack (printOutputable x) == b']
2011+
#endif
20112012
ranges' _ = []
20122013

20132014
rangesForBinding' :: String -> LIE GhcPs -> [SrcSpan]

0 commit comments

Comments
 (0)