package picos_io
Asynchronous IO system for Picos
Install
Dune Dependency
Authors
Maintainers
Sources
picos-0.5.0.tbz
sha256=862d61383e2df93a876bedcffb1fd1ddc0f96c50b0e9c07943a2aee1f0e182be
sha512=87805379017ef4a7f2c11b954625a3757a0f1431bb9ba59132202de278b3e41adbe0cdc20e3ab23b7c9a8c5a15faeb7ec79348e7d80f2b14274b00df0893b8c0
doc/src/picos_io.fd/picos_io_fd.ml.html
Source file picos_io_fd.ml
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34
let report_leaks = ref true module File_descr = struct type t = Unix.file_descr let equal : t -> t -> bool = ( == ) let hash (fd : t) = if Obj.is_int (Obj.repr fd) then Obj.magic fd else Hashtbl.hash fd let dispose = Unix.close end include Picos_aux_rc.Make (File_descr) () let () = Stdlib.at_exit @@ fun () -> if !report_leaks then infos () |> Seq.iter @@ fun info -> if 0 < info.count && info.dispose then begin if Obj.is_int (Obj.repr info.resource) then Printf.eprintf "Leaked file descriptor (%d).\n%!" (Obj.magic info.resource) else Printf.eprintf "Leaked file descriptor.\n%!"; match Printexc.backtrace_slots info.bt with | None -> () | Some slots -> slots |> Array.iteri @@ fun i slot -> if i <> 0 then Printexc.Slot.format i slot |> Option.iter (Printf.eprintf " %s\n%!") end
sectionYPositions = computeSectionYPositions($el), 10)"
x-init="setTimeout(() => sectionYPositions = computeSectionYPositions($el), 10)"
>