diff --git a/hls-haddock-comments-plugin.cabal b/hls-haddock-comments-plugin.cabal
--- a/hls-haddock-comments-plugin.cabal
+++ b/hls-haddock-comments-plugin.cabal
@@ -1,6 +1,6 @@
 cabal-version:      2.4
 name:               hls-haddock-comments-plugin
-version:            1.0.0.3
+version:            1.0.0.4
 synopsis:           Haddock comments plugin for Haskell Language Server
 description:
   Please see the README on GitHub at <https://github.com/haskell/haskell-language-server>
@@ -29,7 +29,7 @@
     , containers
     , ghc
     , ghc-exactprint
-    , ghcide                >=1.2  && <1.5
+    , ghcide                >=1.2  && <1.6
     , hls-plugin-api        >=1.1  && <1.3
     , lsp-types
     , text
diff --git a/src/Ide/Plugin/HaddockComments.hs b/src/Ide/Plugin/HaddockComments.hs
--- a/src/Ide/Plugin/HaddockComments.hs
+++ b/src/Ide/Plugin/HaddockComments.hs
@@ -91,7 +91,9 @@
     isFresh Ann {annsDP} = null [() | (AnnComment _, _) <- annsDP]
     collectKeys = keyFromTyVar 0
 
-#if MIN_VERSION_ghc(9,0,0)
+#if MIN_VERSION_ghc(9,2,0)
+    comment = mkComment "-- ^ " (spanAsAnchor noSrcSpan)
+#elif MIN_VERSION_ghc(9,0,0)
     comment = mkComment "-- ^ " badRealSrcSpan
 #else
     comment = mkComment "-- ^ " noSrcSpan
@@ -114,7 +116,9 @@
 
     collectKeys = keyFromCon
 
-#if MIN_VERSION_ghc(9,0,0)
+#if MIN_VERSION_ghc(9,2,0)
+    comment = mkComment "-- | " (spanAsAnchor noSrcSpan)
+#elif MIN_VERSION_ghc(9,0,0)
     comment = mkComment "-- | " badRealSrcSpan
 #else
     comment = mkComment "-- | " noSrcSpan
@@ -140,7 +144,7 @@
 
 toRange :: SrcSpan -> Maybe Range
 toRange src
-  | (OldRealSrcSpan s) <- src,
+  | (RealSrcSpan s _) <- src,
     range' <- realSrcSpanToRange s =
     Just range'
   | otherwise = Nothing
