Provides an extension trait ([Close]) for closing I/O related
types containing a resource which may return an error when closed.
Provided implementations are for standard library types which implement or contain types which implement:
-
IntoRawFd(Unix) -
IntoRawHandleorIntoRawSocket(Windows).
Using [Close] enables the handling of I/O errors which might
otherwise be ignored during drop.
BufWriter Example
use ;
use Close;