Skip to content

Commit a4e22db

Browse files
prikhiberbermanAilrun
authored
Add CPP Options for Stylish Haskell & Brittany Formatters (#1620)
This fixes an issue where the `stylish-haskell` & `brittany` plugins weren't being added to the enabled plugins list, even if HLS was compiled with their specific flags or the `all-formatters` flag. Also removed the AGPL flag checking when adding the `brittany` plugin, since that is no longer defined anywhere. Co-authored-by: Potato Hatsue <[email protected]> Co-authored-by: Junyoung/Clare Jang <[email protected]>
1 parent ebb5690 commit a4e22db

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

exe/Plugins.hs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ idePlugins includeExamples = pluginDescToIdePlugins allPlugins
110110
#if retrie
111111
Retrie.descriptor "retrie" :
112112
#endif
113-
#if AGPL && brittany
113+
#if brittany
114114
Brittany.descriptor "brittany" :
115115
#endif
116116
#if class

haskell-language-server.cabal

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -264,10 +264,12 @@ common ormolu
264264
common stylishHaskell
265265
if flag(stylishHaskell) || flag(all-formatters)
266266
build-depends: hls-stylish-haskell-plugin ^>= 1.0.0.0
267+
cpp-options: -DstylishHaskell
267268

268269
common brittany
269270
if (flag(brittany) || flag(all-formatters))
270271
build-depends: hls-brittany-plugin ^>= 1.0.0.0
272+
cpp-options: -Dbrittany
271273

272274
executable haskell-language-server
273275
import: common-deps

0 commit comments

Comments
 (0)