1pub mod driver;
4pub mod io;
5pub mod platform;
6pub mod random;
7
8pub use dope_sys::{self, Errno};
9use dope_sys::{
10 engine::{Removal, Source, Storage},
11 table::permit,
12};
13use driver::{
14 life::native::{create, host::Host},
15 receive,
16 result::{IoOperation, Kernel},
17 schedule::ready::Stored,
18};
19pub use o3;
20
21type Engine = <Backend as Source<Host<Backend>>>::Backend;
22type Events = <Backend as Source<Host<Backend>>>::Map;
23type Resources =
24 <Backend as Storage<Host<Backend>, create::Failure, (IoOperation, Kernel)>>::Cleanup;
25type Released =
26 <Backend as Storage<Host<Backend>, create::Failure, (IoOperation, Kernel)>>::Release;
27type RemoveSlot = <Backend as Removal>::Slot;
28type Permits = <Backend as permit::Source>::Queue<Stored, receive::Index>;
29
30#[derive(Debug)]
32pub enum BranchError<A, B> {
33 First(A),
35 Second(B),
37}
38
39cfg_select! {
40 target_os = "linux" => {
41 pub type Backend = dope_uring::Uring;
42 mod ring;
43 use ring as completion;
44 }
45 target_os = "macos" => {
46 pub type Backend = dope_kqueue::Kqueue;
47 mod poll;
48 use poll as completion;
49 }
50}