-
-
Notifications
You must be signed in to change notification settings - Fork 14.2k
Closed as not planned
Labels
T-libs-apiRelevant to the library API team, which will review and decide on the PR/issue.Relevant to the library API team, which will review and decide on the PR/issue.needs-acpThis change is blocked on the author creating an ACP.This change is blocked on the author creating an ACP.
Description
Hello!
I need access to the PATH_SEPARATOR constant that contains the OS specific PATH separator used by std::env::split_paths:
rust/library/std/src/sys/pal/unix/os.rs
Lines 25 to 31 in f7b4354
| cfg_if::cfg_if! { | |
| if #[cfg(target_os = "redox")] { | |
| const PATH_SEPARATOR: u8 = b';'; | |
| } else { | |
| const PATH_SEPARATOR: u8 = b':'; | |
| } | |
| } |
It would be great if this could be exposed similarly to the MAIN_SEPARATOR{,_PATH} constants:
Lines 259 to 270 in f7b4354
| /// The primary separator of path components for the current platform. | |
| /// | |
| /// For example, `/` on Unix and `\` on Windows. | |
| #[stable(feature = "rust1", since = "1.0.0")] | |
| #[cfg_attr(not(test), rustc_diagnostic_item = "path_main_separator")] | |
| pub const MAIN_SEPARATOR: char = crate::sys::path::MAIN_SEP; | |
| /// The primary separator of path components for the current platform. | |
| /// | |
| /// For example, `/` on Unix and `\` on Windows. | |
| #[stable(feature = "main_separator_str", since = "1.68.0")] | |
| pub const MAIN_SEPARATOR_STR: &str = crate::sys::path::MAIN_SEP_STR; |
Thanks!
Metadata
Metadata
Assignees
Labels
T-libs-apiRelevant to the library API team, which will review and decide on the PR/issue.Relevant to the library API team, which will review and decide on the PR/issue.needs-acpThis change is blocked on the author creating an ACP.This change is blocked on the author creating an ACP.