Skip to content

Commit e8b8576

Browse files
committed
Add -Wunused-packages to common warnings
1 parent cd959ae commit e8b8576

File tree

1 file changed

+15
-79
lines changed

1 file changed

+15
-79
lines changed

haskell-language-server.cabal

Lines changed: 15 additions & 79 deletions
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,11 @@ common common-deps
5353

5454
-- Default warnings in HLS
5555
common warnings
56-
ghc-options: -Wall -Wredundant-constraints -Wno-name-shadowing -Wno-unticked-promoted-constructors
56+
ghc-options: -Wall
57+
-Wredundant-constraints
58+
-Wunused-packages
59+
-Wno-name-shadowing
60+
-Wno-unticked-promoted-constructors
5761

5862
flag pedantic
5963
description: Enable -Werror
@@ -430,7 +434,7 @@ flag importLens
430434
manual: True
431435

432436
library hls-explicit-imports-plugin
433-
import: defaults, warnings, pedantic
437+
import: defaults, warnings
434438
exposed-modules: Ide.Plugin.ExplicitImports
435439
hs-source-dirs: plugins/hls-explicit-imports-plugin/src
436440
build-depends:
@@ -447,13 +451,12 @@ library hls-explicit-imports-plugin
447451
, mtl
448452
, text
449453
, transformers
450-
, unordered-containers
451454

452455
default-extensions:
453456
DataKinds
454457

455458
test-suite hls-explicit-imports-plugin-tests
456-
import: defaults, test-defaults, warnings
459+
import: defaults, pedantic, test-defaults, warnings
457460
type: exitcode-stdio-1.0
458461
hs-source-dirs: plugins/hls-explicit-imports-plugin/test
459462
main-is: Main.hs
@@ -490,8 +493,6 @@ library hls-rename-plugin
490493
, base >=4.12 && <5
491494
, containers
492495
, extra
493-
, ghc
494-
, ghc-exactprint
495496
, ghcide == 2.6.0.0
496497
, hashable
497498
, hiedb
@@ -538,15 +539,14 @@ common retrie
538539
cpp-options: -Dhls_retrie
539540

540541
library hls-retrie-plugin
541-
import: defaults, warnings
542+
import: defaults, warnings
542543
exposed-modules: Ide.Plugin.Retrie
543544
hs-source-dirs: plugins/hls-retrie-plugin/src
544545
build-depends:
545546
, aeson
546547
, base >=4.12 && <5
547548
, bytestring
548549
, containers
549-
, deepseq
550550
, directory
551551
, extra
552552
, ghc
@@ -574,7 +574,6 @@ test-suite hls-retrie-plugin-tests
574574
hs-source-dirs: plugins/hls-retrie-plugin/test
575575
main-is: Main.hs
576576
build-depends:
577-
, aeson
578577
, base
579578
, containers
580579
, filepath
@@ -814,7 +813,7 @@ common splice
814813
cpp-options: -Dhls_splice
815814

816815
library hls-splice-plugin
817-
import: defaults, warnings
816+
import: defaults, pedantic, warnings
818817
exposed-modules:
819818
Ide.Plugin.Splice
820819
Ide.Plugin.Splice.Types
@@ -823,8 +822,6 @@ library hls-splice-plugin
823822
build-depends:
824823
, aeson
825824
, base >=4.12 && <5
826-
, containers
827-
, dlist
828825
, extra
829826
, foldl
830827
, ghc
@@ -835,18 +832,16 @@ library hls-splice-plugin
835832
, lens
836833
, lsp
837834
, mtl
838-
, retrie
839835
, syb
840836
, text
841837
, transformers
842838
, unliftio-core
843-
, unordered-containers
844839

845840
default-extensions:
846841
DataKinds
847842

848843
test-suite hls-splice-plugin-tests
849-
import: defaults, test-defaults, warnings
844+
import: defaults, pedantic, test-defaults, warnings
850845
type: exitcode-stdio-1.0
851846
hs-source-dirs: plugins/hls-splice-plugin/test
852847
main-is: Main.hs
@@ -933,22 +928,17 @@ common qualifyImportedNames
933928
cpp-options: -Dhls_qualifyImportedNames
934929

935930
library hls-qualify-imported-names-plugin
936-
import: defaults, warnings
931+
import: defaults, pedantic, warnings
937932
exposed-modules: Ide.Plugin.QualifyImportedNames
938933
hs-source-dirs: plugins/hls-qualify-imported-names-plugin/src
939934
build-depends:
940-
, aeson
941935
, base >=4.12 && <5
942936
, containers
943-
, deepseq
944-
, ghc
945937
, ghcide == 2.6.0.0
946-
, hls-graph
947938
, hls-plugin-api == 2.6.0.0
948939
, lens
949940
, lsp
950941
, text
951-
, unordered-containers
952942
, dlist
953943
, transformers
954944

@@ -1558,7 +1548,7 @@ common semanticTokens
15581548
cpp-options: -Dhls_semanticTokens
15591549

15601550
library hls-semantic-tokens-plugin
1561-
import: defaults, warnings
1551+
import: defaults, pedantic, warnings
15621552
buildable: True
15631553
exposed-modules:
15641554
Ide.Plugin.SemanticTokens
@@ -1573,20 +1563,16 @@ library hls-semantic-tokens-plugin
15731563

15741564
hs-source-dirs: plugins/hls-semantic-tokens-plugin/src
15751565
build-depends:
1576-
, aeson
15771566
, base >=4.12 && <5
15781567
, containers
15791568
, extra
1580-
, hiedb
15811569
, text-rope
15821570
, mtl >= 2.2
15831571
, ghcide == 2.6.0.0
15841572
, hls-plugin-api == 2.6.0.0
15851573
, lens
15861574
, lsp >=2.3
1587-
, sqlite-simple
15881575
, text
1589-
, unordered-containers
15901576
, transformers
15911577
, bytestring
15921578
, syb
@@ -1599,7 +1585,7 @@ library hls-semantic-tokens-plugin
15991585
default-extensions: DataKinds
16001586

16011587
test-suite hls-semantic-tokens-plugin-tests
1602-
import: defaults, test-defaults, warnings
1588+
import: defaults, pedantic, test-defaults, warnings
16031589
type: exitcode-stdio-1.0
16041590
hs-source-dirs: plugins/hls-semantic-tokens-plugin/test
16051591
main-is: Main.hs
@@ -1608,7 +1594,6 @@ test-suite hls-semantic-tokens-plugin-tests
16081594
, aeson
16091595
, base
16101596
, containers
1611-
, extra
16121597
, filepath
16131598
, haskell-language-server:hls-semantic-tokens-plugin
16141599
, hls-test-utils == 2.6.0.0
@@ -1621,10 +1606,8 @@ test-suite hls-semantic-tokens-plugin-tests
16211606
, lsp-test
16221607
, text
16231608
, data-default
1624-
, bytestring
16251609
, ghcide == 2.6.0.0
16261610
, hls-plugin-api == 2.6.0.0
1627-
, template-haskell
16281611
, data-default
16291612

16301613
-----------------------------
@@ -1675,26 +1658,15 @@ library
16751658
autogen-modules: Paths_haskell_language_server
16761659
hs-source-dirs: src
16771660
build-depends:
1678-
, async
1679-
, base16-bytestring
1680-
, bytestring
1681-
, containers
1682-
, cryptohash-sha1
16831661
, data-default
16841662
, ghc
16851663
, ghcide == 2.6.0.0
16861664
, githash >=0.1.6.1
1687-
, lsp >= 2.3.0.0
16881665
, hie-bios
1689-
, hiedb
16901666
, hls-plugin-api == 2.6.0.0
16911667
, optparse-applicative
16921668
, optparse-simple
16931669
, process
1694-
, hls-graph
1695-
, safe-exceptions
1696-
, sqlite-simple
1697-
, unordered-containers
16981670
, aeson-pretty
16991671

17001672
default-extensions: DataKinds
@@ -1728,36 +1700,9 @@ executable haskell-language-server
17281700
ghc-options: -dynamic
17291701

17301702
build-depends:
1731-
, aeson
1732-
, async
1733-
, base16-bytestring
1734-
, binary
1735-
, bytestring
1736-
, containers
1737-
, cryptohash-sha1
1738-
, deepseq
1739-
, ghc
1740-
, ghc-boot-th
1741-
, ghcide
1742-
, hashable
17431703
, haskell-language-server
17441704
, lsp
1745-
, hie-bios
1746-
, hiedb
1747-
, lens
1748-
, regex-tdfa
1749-
, optparse-applicative
17501705
, hls-plugin-api
1751-
, lens
1752-
, mtl
1753-
, regex-tdfa
1754-
, safe-exceptions
1755-
, hls-graph
1756-
, sqlite-simple
1757-
, stm
1758-
, temporary
1759-
, transformers
1760-
, unordered-containers
17611706

17621707
default-extensions: DataKinds
17631708

@@ -1781,18 +1726,12 @@ executable haskell-language-server-wrapper
17811726
build-depends:
17821727
, data-default
17831728
, ghc
1784-
, ghc-paths
17851729
, ghcide
1786-
, gitrev
17871730
, haskell-language-server
17881731
, hie-bios
17891732
, hls-plugin-api
17901733
, lsp
17911734
, lsp-types
1792-
, mtl
1793-
, optparse-applicative
1794-
, optparse-simple
1795-
, process
17961735
, transformers
17971736
, unliftio-core
17981737
if !os(windows)
@@ -1816,11 +1755,9 @@ test-suite func-test
18161755

18171756
build-depends:
18181757
, bytestring
1819-
, data-default
18201758
, deepseq
18211759
, hashable
18221760
, lens
1823-
, lens-aeson
18241761
, ghcide
18251762
, ghcide-test-utils
18261763
, hls-test-utils == 2.6.0.0
@@ -1830,7 +1767,6 @@ test-suite func-test
18301767
, lsp-test
18311768
, containers
18321769
, unordered-containers
1833-
, row-types
18341770

18351771
hs-source-dirs: test/functional test/utils
18361772

@@ -1859,7 +1795,8 @@ test-suite func-test
18591795
cpp-options: -Dhls_ormolu
18601796

18611797
test-suite wrapper-test
1862-
import: defaults, common-deps
1798+
import: defaults
1799+
, common-deps
18631800
, warnings
18641801
, pedantic
18651802
type: exitcode-stdio-1.0
@@ -1901,7 +1838,6 @@ benchmark benchmark
19011838
hls-plugin-api,
19021839
lens,
19031840
lens-aeson,
1904-
optparse-applicative,
19051841
shake,
19061842
shake-bench == 0.2.*,
19071843
yaml

0 commit comments

Comments
 (0)