File tree 3 files changed +10
-10
lines changed 3 files changed +10
-10
lines changed Original file line number Diff line number Diff line change @@ -12,6 +12,7 @@ import Language.Haskell.Brittany
12
12
import Language.Haskell.LSP.Types as J
13
13
import qualified Language.Haskell.LSP.Types.Lens as J
14
14
import Ide.Plugin.Formatter
15
+ import Ide.PluginUtils
15
16
import Ide.Types
16
17
17
18
import System.FilePath
@@ -61,11 +62,6 @@ formatText confFile opts text =
61
62
liftIO $ runBrittany tabSize confFile text
62
63
where tabSize = opts ^. J. tabSize
63
64
64
- -- | Extend to the line below and above to replace newline character.
65
- normalize :: Range -> Range
66
- normalize (Range (Position sl _) (Position el _)) =
67
- Range (Position sl 0 ) (Position (el + 1 ) 0 )
68
-
69
65
-- | Recursively search in every directory of the given filepath for brittany.yaml.
70
66
-- If no such file has been found, return Nothing.
71
67
getConfFile :: NormalizedFilePath -> IO (Maybe FilePath )
Original file line number Diff line number Diff line change @@ -90,8 +90,3 @@ provider _lf ideState typ contents fp _ = do
90
90
#else
91
91
provider _ _ _ _ = return $ Right [] -- NOP formatter
92
92
#endif
93
-
94
- -- | Extend to the line below and above to replace newline character.
95
- normalize :: Range -> Range
96
- normalize (Range (Position sl _) (Position el _)) =
97
- Range (Position sl 0 ) (Position (el + 1 ) 0 )
Original file line number Diff line number Diff line change @@ -10,6 +10,15 @@ import Language.Haskell.LSP.Types.Capabilities
10
10
import qualified Language.Haskell.LSP.Types as J
11
11
import Language.Haskell.LSP.Types
12
12
13
+ -- ---------------------------------------------------------------------
14
+
15
+ -- | Extend to the line below and above to replace newline character.
16
+ normalize :: Range -> Range
17
+ normalize (Range (Position sl _) (Position el _)) =
18
+ Range (Position sl 0 ) (Position (el + 1 ) 0 )
19
+
20
+ -- ---------------------------------------------------------------------
21
+
13
22
data WithDeletions = IncludeDeletions | SkipDeletions
14
23
deriving Eq
15
24
You can’t perform that action at this time.
0 commit comments