aboutsummaryrefslogtreecommitdiff
path: root/lib/libcxx/src/filesystem/directory_entry.cpp
diff options
context:
space:
mode:
authorAndrew Kelley <andrew@ziglang.org>2024-05-09 01:52:26 -0700
committerAndrew Kelley <andrew@ziglang.org>2024-05-09 01:52:26 -0700
commitbcb534c295d5cc6fd63caa570cc08e6b148a507c (patch)
tree0b17cb1e632d894f50f25e550d5113f232b0e877 /lib/libcxx/src/filesystem/directory_entry.cpp
parentd9b00ee4ba48717ff6b306a6f9419e7b604ac04b (diff)
parent74f52954b9cb40d59d80b839b45bb859146731a7 (diff)
downloadzig-bcb534c295d5cc6fd63caa570cc08e6b148a507c.tar.gz
zig-bcb534c295d5cc6fd63caa570cc08e6b148a507c.zip
Merge branch 'llvm18'
Upgrades the LLVM, Clang, and LLD dependencies to LLVM 18.x Related to #16270
Diffstat (limited to 'lib/libcxx/src/filesystem/directory_entry.cpp')
-rw-r--r--lib/libcxx/src/filesystem/directory_entry.cpp15
1 files changed, 7 insertions, 8 deletions
diff --git a/lib/libcxx/src/filesystem/directory_entry.cpp b/lib/libcxx/src/filesystem/directory_entry.cpp
index 4910d390d1..1527152439 100644
--- a/lib/libcxx/src/filesystem/directory_entry.cpp
+++ b/lib/libcxx/src/filesystem/directory_entry.cpp
@@ -28,9 +28,9 @@ error_code directory_entry::__do_refresh() noexcept {
return failure_ec;
}
- if (!_VSTD_FS::exists(st) || !_VSTD_FS::is_symlink(st)) {
- __data_.__cache_type_ = directory_entry::_RefreshNonSymlink;
- __data_.__type_ = st.type();
+ if (!filesystem::exists(st) || !filesystem::is_symlink(st)) {
+ __data_.__cache_type_ = directory_entry::_RefreshNonSymlink;
+ __data_.__type_ = st.type();
__data_.__non_sym_perms_ = st.permissions();
} else { // we have a symlink
__data_.__sym_perms_ = st.permissions();
@@ -40,7 +40,7 @@ error_code directory_entry::__do_refresh() noexcept {
error_code ignored_ec;
st = detail::posix_stat(__p_, full_st, &ignored_ec);
- __data_.__type_ = st.type();
+ __data_.__type_ = st.type();
__data_.__non_sym_perms_ = st.permissions();
// If we failed to resolve the link, then only partially populate the
@@ -54,18 +54,17 @@ error_code directory_entry::__do_refresh() noexcept {
__data_.__cache_type_ = directory_entry::_RefreshSymlink;
}
- if (_VSTD_FS::is_regular_file(st))
+ if (filesystem::is_regular_file(st))
__data_.__size_ = static_cast<uintmax_t>(full_st.st_size);
- if (_VSTD_FS::exists(st)) {
+ if (filesystem::exists(st)) {
__data_.__nlink_ = static_cast<uintmax_t>(full_st.st_nlink);
// Attempt to extract the mtime, and fail if it's not representable using
// file_time_type. For now we ignore the error, as we'll report it when
// the value is actually used.
error_code ignored_ec;
- __data_.__write_time_ =
- detail::__extract_last_write_time(__p_, full_st, &ignored_ec);
+ __data_.__write_time_ = detail::__extract_last_write_time(__p_, full_st, &ignored_ec);
}
return failure_ec;