From c999f38356ce5c291296ab2e09ea584df45d2a9b Mon Sep 17 00:00:00 2001 From: Chris Wong Date: Sat, 7 Jan 2023 21:08:03 +1100 Subject: [PATCH] Add comparison with `std::io::Error` --- README.md | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/README.md b/README.md index 610ad84..48def10 100644 --- a/README.md +++ b/README.md @@ -17,6 +17,19 @@ errno = "*" ``` +## Comparison with `std::io::Error` + +The standard library provides [`Error::last_os_error`][last_os_error] which fetches `errno` in the same way. + +This crate provides these extra features: + +- No heap allocations +- Optional `#![no_std]` support +- A `set_errno` function + +[last_os_error]: https://doc.rust-lang.org/std/io/struct.Error.html#method.last_os_error + + ## Examples ```rust