Skip to content

Commit a30385a

Browse files
authored
Merge pull request #1904 from ahoppen/log-cancellation
Emit a log message when we receive a cancel request notification
2 parents ede4088 + 7b43383 commit a30385a

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

Sources/LanguageServerProtocolExtensions/QueueBasedMessageHandler.swift

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,15 +10,15 @@
1010
//
1111
//===----------------------------------------------------------------------===//
1212

13-
#if compiler(>=6)
1413
import Foundation
15-
package import LanguageServerProtocol
14+
import LanguageServerProtocolJSONRPC
1615
import SKLogging
16+
17+
#if compiler(>=6)
18+
package import LanguageServerProtocol
1719
package import SwiftExtensions
1820
#else
19-
import Foundation
2021
import LanguageServerProtocol
21-
import SKLogging
2222
import SwiftExtensions
2323
#endif
2424

@@ -180,6 +180,7 @@ extension QueueBasedMessageHandler {
180180
// are currently handling. Ordering is not important here. We thus don't
181181
// need to execute it on `messageHandlingQueue`.
182182
if let notification = notification as? CancelRequestNotification {
183+
logger.log("Received cancel request notification: \(notification.forLogging)")
183184
self.messageHandlingHelper.cancelRequest(id: notification.id)
184185
return
185186
}

0 commit comments

Comments
 (0)