Skip to content

Commit

Permalink
Qualify match with a further check rather than remove it
Browse files Browse the repository at this point in the history
  • Loading branch information
purcell authored Jan 16, 2024
1 parent 5b54d4b commit 37a3de8
Showing 1 changed file with 2 additions and 7 deletions.
9 changes: 2 additions & 7 deletions haskell-load.el
Original file line number Diff line number Diff line change
Expand Up @@ -205,13 +205,8 @@ list of modules where missed IDENT was found."
(string-match
"Use \\([A-Z][A-Za-z]+\\) if you want to disable this"
msg)
;; Andreas Abel, 2024-01-10, https://github.com/haskell/haskell-mode/issues/1834
;; The following regex also matches the new x-partial warning
;; "Consider refactoring to use Data.List.NonEmpty"
;; which would result in a suggestion to
;; "Add {-# LANGUAGE Data #-} to the top of the file?"
;; Thus, we disable it.
;; (string-match "use \\([A-Z][A-Za-z]+\\)" msg)
(and (string-match "use \\([A-Z][A-Za-z]+\\)" msg)
(not (string-match "refactoring to use" msg)))
(string-match "You need \\([A-Z][A-Za-z]+\\)" msg)))
(when haskell-process-suggest-language-pragmas
(haskell-process-suggest-pragma
Expand Down

0 comments on commit 37a3de8

Please sign in to comment.