Skip to content

Ship hls-hlint-plugin for ghc-9.6 #3677

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jun 28, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -162,11 +162,11 @@ jobs:
name: Test hls-splice-plugin
run: cabal test hls-splice-plugin --test-options="$TEST_OPTS" || cabal test hls-splice-plugin --test-options="$TEST_OPTS"

- if: matrix.test
- if: matrix.test
name: Test hls-stylish-haskell-plugin
run: cabal test hls-stylish-haskell-plugin --test-options="$TEST_OPTS" || cabal test hls-stylish-haskell-plugin --test-options="$TEST_OPTS"

- if: matrix.test
- if: matrix.test
name: Test hls-ormolu-plugin
run: cabal test hls-ormolu-plugin --test-options="$TEST_OPTS" || cabal test hls-ormolu-plugin --test-options="$TEST_OPTS"

Expand Down Expand Up @@ -194,7 +194,7 @@ jobs:
name: Test hls-rename-plugin test suite
run: cabal test hls-rename-plugin --test-options="$TEST_OPTS" || cabal test hls-rename-plugin --test-options="$TEST_OPTS"

- if: matrix.test && matrix.ghc != '9.6'
- if: matrix.test
name: Test hls-hlint-plugin test suite
run: cabal test hls-hlint-plugin --test-options="$TEST_OPTS" || cabal test hls-hlint-plugin --test-options="$TEST_OPTS"

Expand Down
2 changes: 1 addition & 1 deletion cabal.project
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ package *

write-ghc-environment-files: never

index-state: 2023-06-25T00:00:00Z
index-state: 2023-06-27T10:50:26Z

constraints:
-- For GHC 9.4, older versions of entropy fail to build on Windows
Expand Down
2 changes: 1 addition & 1 deletion docs/support/plugin-support.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ For example, a plugin to provide a formatter which has itself been abandoned has
| `hls-floskell-plugin` | 2 | 9.6 |
| `hls-fourmolu-plugin` | 2 | |
| `hls-gadt-plugin` | 2 | |
| `hls-hlint-plugin` | 2 | 9.6 |
| `hls-hlint-plugin` | 2 | |
| `hls-module-name-plugin` | 2 | |
| `hls-qualify-imported-names-plugin` | 2 | |
| `hls-ormolu-plugin` | 2 | |
Expand Down
4 changes: 2 additions & 2 deletions haskell-language-server.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -272,7 +272,7 @@ common tactic
cpp-options: -Dhls_tactic

common hlint
if flag(hlint) && impl(ghc < 9.5)
if flag(hlint)
build-depends: hls-hlint-plugin == 2.1.0.0
cpp-options: -Dhls_hlint

Expand Down Expand Up @@ -354,7 +354,7 @@ common ormolu
cpp-options: -Dhls_ormolu

common stylishHaskell
if flag(stylishHaskell)
if flag(stylishHaskell)
build-depends: hls-stylish-haskell-plugin == 2.1.0.0
cpp-options: -Dhls_stylishHaskell

Expand Down
6 changes: 1 addition & 5 deletions plugins/hls-hlint-plugin/hls-hlint-plugin.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,6 @@ flag pedantic
manual: True

library
if impl(ghc >= 9.5)
buildable: False
exposed-modules: Ide.Plugin.Hlint
hs-source-dirs: src
build-depends:
Expand All @@ -49,7 +47,7 @@ library
, ghc-exactprint >=0.6.3.4
, ghcide == 2.1.0.0
, hashable
, hlint < 3.6
, hlint < 3.7
, hls-plugin-api == 2.1.0.0
, lens
, lsp
Expand Down Expand Up @@ -78,8 +76,6 @@ library
TypeOperators

test-suite tests
if impl(ghc >= 9.5)
buildable: False
type: exitcode-stdio-1.0
default-language: Haskell2010
hs-source-dirs: test
Expand Down
4 changes: 2 additions & 2 deletions plugins/hls-hlint-plugin/test/Main.hs
Original file line number Diff line number Diff line change
Expand Up @@ -185,11 +185,11 @@ suggestionsTests =
doc <- openDoc "IgnoreAnnHlint.hs" "haskell"
expectNoMoreDiagnostics 3 doc "hlint"

, knownBrokenForGhcVersions [GHC92, GHC94] "apply-refact has different behavior on v0.10" $
, knownBrokenForGhcVersions [GHC92, GHC94, GHC96] "apply-refact has different behavior on v0.10" $
testCase "apply-refact preserve regular comments" $ runHlintSession "" $ do
testRefactor "Comments.hs" "Redundant bracket" expectedComments

, onlyRunForGhcVersions [GHC92, GHC94] "only run test for apply-refact-0.10" $
, onlyRunForGhcVersions [GHC92, GHC94, GHC96] "only run test for apply-refact-0.10" $
testCase "apply-refact preserve regular comments" $ runHlintSession "" $ do
testRefactor "Comments.hs" "Redundant bracket" expectedComments'

Expand Down