From 2ec1dff66ddba93cafd31e42e01f13d6564a7489 Mon Sep 17 00:00:00 2001 From: nori li <50680474+thenorili@users.noreply.github.com> Date: Tue, 7 Nov 2023 13:46:13 -0800 Subject: [PATCH] Update documentation on no_std support. (#111) no_std support was removed in 2020 with PR #29. This change updates the documentation to reflect that as suggested in PR #89. It still mentions no_std, which will hopefully keep it on our minds enough to check sometimes and see if the upstream problem has been resolved. Co-authored-by: Jane Losare-Lusby --- README.md | 20 +++----------------- eyre/src/lib.rs | 20 +++----------------- 2 files changed, 6 insertions(+), 34 deletions(-) diff --git a/README.md b/README.md index 7510416..6dd66e8 100644 --- a/README.md +++ b/README.md @@ -171,23 +171,9 @@ avoid using `eyre::Report` as your public error type. ## No-std support -**NOTE**: tests are currently broken for `no_std` so I cannot guarantee that -everything works still. I'm waiting for upstream fixes to be merged rather than -fixing them myself, so bear with me. - -In no_std mode, the same API is almost all available and works the same way. To -depend on Eyre in no_std mode, disable our default enabled "std" feature in -Cargo.toml. A global allocator is required. - -```toml -[dependencies] -eyre = { version = "0.6", default-features = false } -``` - -Since the `?`-based error conversions would normally rely on the -`std::error::Error` trait which is only available through std, no_std mode will -require an explicit `.map_err(Report::msg)` when working with a non-Eyre error -type inside a function that returns Eyre's error type. +No-std support was removed in 2020 in [commit 608a16a] due to unaddressed upstream breakages. +[commit 608a16a]: +https://github.com/eyre-rs/eyre/pull/29/commits/608a16aa2c2c27eca6c88001cc94c6973c18f1d5 ## Comparison to failure diff --git a/eyre/src/lib.rs b/eyre/src/lib.rs index d3381a0..39d4316 100644 --- a/eyre/src/lib.rs +++ b/eyre/src/lib.rs @@ -236,23 +236,9 @@ //! //! ## No-std support //! -//! **NOTE**: tests are currently broken for `no_std` so I cannot guarantee that -//! everything works still. I'm waiting for upstream fixes to be merged rather than -//! fixing them myself, so bear with me. -//! -//! In no_std mode, almost all the API is available and works the same way. To -//! depend on Eyre in no_std mode, disable our default enabled "std" feature in -//! Cargo.toml. A global allocator is required. -//! -//! ```toml -//! [dependencies] -//! eyre = { version = "0.6", default-features = false } -//! ``` -//! -//! Since the `?`-based error conversions would normally rely on the -//! `std::error::Error` trait which is only available through std, no_std mode will -//! require an explicit `.map_err(Report::msg)` when working with a non-Eyre error -//! type inside a function that returns Eyre's error type. +//! No-std support was removed in 2020 in [commit 608a16a] due to unaddressed upstream breakages. +//! [commit 608a16a]: +//! https://github.com/eyre-rs/eyre/pull/29/commits/608a16aa2c2c27eca6c88001cc94c6973c18f1d5 //! //! ## Comparison to failure //!