Skip to content

Commit 601c38c

Browse files
committed
fix: Use updated traversal for error messages _TcRnMessage -> _TcRnMessageWithCtx
1 parent a8d1a4b commit 601c38c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

plugins/hls-change-type-signature-plugin/src/Ide/Plugin/ChangeTypeSignature.hs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ import Development.IDE (FileDiagnostic,
2929
import Development.IDE.Core.PluginUtils
3030
import Development.IDE.Core.RuleTypes (GetParsedModule (GetParsedModule))
3131
import Development.IDE.GHC.Compat hiding (vcat)
32-
import Development.IDE.GHC.Compat.Error (_TcRnMessage,
32+
import Development.IDE.GHC.Compat.Error (_TcRnMessageWithCtx,
3333
msgEnvelopeErrorL)
3434
import Development.IDE.GHC.Util (printOutputable)
3535
import Development.IDE.Types.Diagnostics (_SomeStructuredMessage)
@@ -137,7 +137,7 @@ diagnosticToChangeSig recorder decls diagnostic = runMaybeT $ do
137137
-- Extract expected, actual, and extra error info
138138
(expectedType, actualType, errInfo) <- hoistMaybe $ do
139139
msg <- diagnostic ^. fdStructuredMessageL ^? _SomeStructuredMessage
140-
tcRnMsg <- msg ^. msgEnvelopeErrorL ^? _TcRnMessage
140+
tcRnMsg <- msg ^. msgEnvelopeErrorL ^? _TcRnMessageWithCtx
141141
TcRnMessageDetailed errInfo tcRnMsg' <- tcRnMsg ^? _TcRnMessageDetailed
142142
solverReport <- tcRnMsg' ^? _TcRnSolverReport . tcSolverReportMsgL
143143
mismatch <- solverReport ^? _MismatchMessage

0 commit comments

Comments
 (0)