Skip to content

Commit

Permalink
Update src/Compiler/Utilities/Cancellable.fs
Browse files Browse the repository at this point in the history
Co-authored-by: Tomas Grosup <[email protected]>
  • Loading branch information
auduchinok and T-Gro authored Jan 28, 2025
1 parent d68c21f commit fbdf39a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Compiler/Utilities/Cancellable.fs
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ module Cancellable =
use _ = Cancellable.UsingToken(ct)
oper ct
with
| :? OperationCanceledException as e when e.CancellationToken = ct -> ValueOrCancelled.Cancelled e
| :? OperationCanceledException as e when ct.IsCancellationRequested -> ValueOrCancelled.Cancelled e
| :? OperationCanceledException as e -> InvalidOperationException("Wrong cancellation token", e) |> raise

let fold f acc seq =
Expand Down

0 comments on commit fbdf39a

Please sign in to comment.