-"File descriptors" in `compio` represents the file descriptors on Unix and handles on Windows. When the driver is holding the operations, it should also hold the reference of the related fds. Therefore, all fds are wrapped inside an `Rc`/`Arc`, depending on the feature `"sync"`. When a file or socket is cloned, the inner `Rc`/`Arc` is cloned, rather than duplicating (e.g., with `dup`) the fds or handles. When the method `close` is called on a file or socket, the future will wait for all related operations to complete. Therefore, it's not a good idea to close a cloned file or socket.
0 commit comments