From 5b05846fb0eb53a30cb6ddfee1c282b95fa56be7 Mon Sep 17 00:00:00 2001 From: Yoshua Wuyts Date: Sun, 6 Oct 2019 13:42:55 +0200 Subject: [PATCH] init path submodule as unstable Signed-off-by: Yoshua Wuyts --- src/lib.rs | 2 ++ src/path/mod.rs | 21 +++++++++++++++++++++ 2 files changed, 23 insertions(+) create mode 100644 src/path/mod.rs diff --git a/src/lib.rs b/src/lib.rs index 839a0ec..fa4e946 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -62,6 +62,8 @@ pub mod task; cfg_if! { if #[cfg(any(feature = "unstable", feature = "docs"))] { + #[cfg_attr(feature = "docs", doc(cfg(unstable)))] + pub mod path; #[cfg_attr(feature = "docs", doc(cfg(unstable)))] pub mod pin; diff --git a/src/path/mod.rs b/src/path/mod.rs new file mode 100644 index 0000000..9153243 --- /dev/null +++ b/src/path/mod.rs @@ -0,0 +1,21 @@ +//! Cross-platform path manipulation. +//! +//! This module is an async version of [`std::path`]. +//! +//! [`std::path`]: https://doc.rust-lang.org/std/path/index.html + +// Structs re-export +#[doc(inline)] +pub use std::path::{Ancestors, Components, Display, Iter, PrefixComponent, StripPrefixError}; + +// Enums re-export +#[doc(inline)] +pub use std::path::{Component, Prefix}; + +// Constants re-export +#[doc(inline)] +pub use std::path::MAIN_SEPARATOR; + +// Functions re-export +#[doc(inline)] +pub use std::path::is_separator;