Skip to content

Commit

Permalink
Fix build on OCaml 5.0 (remove deprecated Thread.kill)
Browse files Browse the repository at this point in the history
  • Loading branch information
OlivierNicole authored and gildor478 committed Jan 22, 2022
1 parent faf4936 commit d8893bb
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions src/lib/ounit2/threads/oUnitRunnerThreads.ml
Expand Up @@ -143,10 +143,9 @@ let create_worker ~shard_id ~master_id ~worker_log_file conf map_test_cases =
Mutex.lock worker_finished_mutex
done;
if not !worker_finished then begin
(* This will fail... because probably not implemented. *)
Thread.kill thread;
worker_finished := true;
Condition.broadcast worker_finished_cond
(* We should kill [thread] here but there seems to be no way to kill a
thread so we will just fail. *)
raise (Invalid_argument "Thread.kill not implemented")
end;
Mutex.unlock worker_finished_mutex
in
Expand Down

0 comments on commit d8893bb

Please sign in to comment.