File tree Expand file tree Collapse file tree 1 file changed +9
-10
lines changed
Expand file tree Collapse file tree 1 file changed +9
-10
lines changed Original file line number Diff line number Diff line change @@ -714,22 +714,21 @@ let definition_query server (state : State.t) uri position merlin_request =
714714 in
715715 None
716716
717- let await_no_cancel task =
718- let + res = Lev_fiber.Thread. await task in
719- match res with
720- | Ok s -> s
721- | Error `Cancelled -> assert false
722- | Error (`Exn exn ) -> Exn_with_backtrace. reraise exn
723-
724717let workspace_symbol server (state : State.t ) (params : WorkspaceSymbolParams.t )
725718 =
726719 let * symbols, errors =
727720 let workspaces = Workspaces. workspace_folders (State. workspaces state) in
728721 let * thread = Lazy_fiber. force state.symbols_thread in
729722 let + symbols_results =
730- Lev_fiber.Thread. task thread ~f: (fun () ->
731- Workspace_symbol. run params workspaces)
732- >> = await_no_cancel
723+ let * task =
724+ Lev_fiber.Thread. task thread ~f: (fun () ->
725+ Workspace_symbol. run params workspaces)
726+ in
727+ let + res = Lev_fiber.Thread. await task in
728+ match res with
729+ | Ok s -> s
730+ | Error `Cancelled -> assert false
731+ | Error (`Exn exn ) -> Exn_with_backtrace. reraise exn
733732 in
734733 List. partition_map symbols_results ~f: (function
735734 | Ok r -> Left r
You can’t perform that action at this time.
0 commit comments