Skip to content

Commit 6a66ad2

Browse files
dylan-thinnesJaro Reinders
authored and
Jaro Reinders
committed
Properly split GHC.Types.Error import in Diagnostics for stylish-haskell
1 parent 4fd35fd commit 6a66ad2

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

ghcide/src/Development/IDE/Types/Diagnostics.hs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,11 +40,17 @@ import Development.IDE.GHC.Compat (GhcMessage, MsgEnvelope,
4040
flagSpecName, wWarningFlags)
4141
import Development.IDE.Types.Location
4242
import GHC.Generics
43+
#if MIN_VERSION_ghc(9,6,1)
4344
import GHC.Types.Error (DiagnosticCode (..),
4445
DiagnosticReason (..),
4546
diagnosticCode,
4647
diagnosticReason,
4748
errMsgDiagnostic)
49+
#else
50+
import GHC.Types.Error (DiagnosticReason (..),
51+
diagnosticReason,
52+
errMsgDiagnostic)
53+
#endif
4854
import Language.LSP.Diagnostics
4955
import Language.LSP.Protocol.Lens (data_)
5056
import Language.LSP.Protocol.Types as LSP

0 commit comments

Comments
 (0)