about summary refs log tree commit diff
path: root/library/std/src/sys/path/sgx.rs
diff options
context:
space:
mode:
Diffstat (limited to 'library/std/src/sys/path/sgx.rs')
-rw-r--r--library/std/src/sys/path/sgx.rs4
1 files changed, 4 insertions, 0 deletions
diff --git a/library/std/src/sys/path/sgx.rs b/library/std/src/sys/path/sgx.rs
index c805c15e702..32c7752f605 100644
--- a/library/std/src/sys/path/sgx.rs
+++ b/library/std/src/sys/path/sgx.rs
@@ -23,3 +23,7 @@ pub const MAIN_SEP: char = '/';
 pub(crate) fn absolute(_path: &Path) -> io::Result<PathBuf> {
     unsupported()
 }
+
+pub(crate) fn is_absolute(path: &Path) -> bool {
+    path.has_root() && path.prefix().is_some()
+}