Implement <filesystem>

This patch implements the <filesystem> header and uses that
to provide <experimental/filesystem>.

Unlike other standard headers, the symbols needed for <filesystem>
have not yet been placed in libc++.so. Instead they live in the
new libc++fs.a library. Users of filesystem are required to link this
library. (Also note that libc++experimental no longer contains the
definition of <experimental/filesystem>, which now requires linking libc++fs).

The reason for keeping <filesystem> out of the dylib for now is that
it's still somewhat experimental, and the possibility of requiring an
ABI breaking change is very real. In the future the symbols will likely
be moved into the dylib, or the dylib will be made to link libc++fs automagically).

Note that moving the symbols out of libc++experimental may break user builds
until they update to -lc++fs. This should be OK, because the experimental
library provides no stability guarantees. However, I plan on looking into
ways we can force libc++experimental to automagically link libc++fs.

In order to use a single implementation and set of tests for <filesystem>, it
has been placed in a special `__fs` namespace. This namespace is inline in
C++17 onward, but not before that. As such implementation is available
in C++11 onward, but no filesystem namespace is present "directly", and
as such name conflicts shouldn't occur in C++11 or C++14.

llvm-svn: 338093
This commit is contained in:
Eric Fiselier 2018-07-27 03:07:09 +00:00
parent 567485a72f
commit 998a5c8831
178 changed files with 3978 additions and 3161 deletions

View File

@ -107,6 +107,10 @@ option(LIBCXX_INSTALL_SUPPORT_HEADERS "Install libc++ support headers." ON)
cmake_dependent_option(LIBCXX_INSTALL_EXPERIMENTAL_LIBRARY
"Install libc++experimental.a" ON
"LIBCXX_ENABLE_EXPERIMENTAL_LIBRARY;LIBCXX_INSTALL_LIBRARY" OFF)
cmake_dependent_option(LIBCXX_INSTALL_FILESYSTEM_LIBRARY
"Install libc++fs.a" ON
"LIBCXX_ENABLE_FILESYSTEM_LIBRARY;LIBCXX_INSTALL_LIBRARY" OFF)
if (FUCHSIA)
set(DEFAULT_ABI_VERSION 2)
else()

View File

@ -242,11 +242,15 @@ libc++experimental Specific Options
.. option:: LIBCXX_ENABLE_FILESYSTEM:BOOL
**Default**: ``LIBCXX_ENABLE_EXPERIMENTAL_LIBRARY``
**Default**: ``ON``
Build filesystem as part of libc++experimental.a. This allows filesystem
to be disabled without turning off the entire experimental library.
Build filesystem as a standalone library libc++fs.a.
.. option:: LIBCXX_INSTALL_FILESYSTEM_LIBRARY:BOOL
**Default**: ``LIBCXX_ENABLE_FILESYSTEM AND LIBCXX_INSTALL_LIBRARY``
Install libc++fs.a alongside libc++.
.. _ABI Library Specific Options:

View File

@ -49,6 +49,24 @@ An example of using ``LD_LIBRARY_PATH``:
$ export LD_LIBRARY_PATH=<libcxx-install-prefix>/lib
$ ./a.out # Searches for libc++ along LD_LIBRARY_PATH
Using ``<filesystem>`` and libc++fs
====================================
Libc++ provides the implementation of the filesystem library in a separate
library. Users of ``<filesystem>`` and ``<experimental/filesystem>`` are
required to link ``-lc++fs``.
.. note::
Prior to libc++ 7.0, users of ``<experimental/filesystem>`` were required
to link libc++experimental.
.. warning::
The Filesystem library is still experimental in nature. As such normal
guarantees about ABI stability and backwards compatibility do not yet apply
to it. In the future, this restriction will be removed.
Using libc++experimental and ``<experimental/...>``
=====================================================
@ -65,6 +83,9 @@ installed. For information on building libc++experimental from source see
:ref:`Building Libc++ <build instructions>` and
:ref:`libc++experimental CMake Options <libc++experimental options>`.
Note that as of libc++ 7.0 using the ``<experimental/filesystem>`` requires linking
libc++fs instead of libc++experimental.
Also see the `Experimental Library Implementation Status <http://libcxx.llvm.org/ts1z_status.html>`__
page.

View File

@ -43,6 +43,18 @@
# endif
#endif
#ifndef _LIBCPP_STD_VER
# if __cplusplus <= 201103L
# define _LIBCPP_STD_VER 11
# elif __cplusplus <= 201402L
# define _LIBCPP_STD_VER 14
# elif __cplusplus <= 201703L
# define _LIBCPP_STD_VER 17
# else
# define _LIBCPP_STD_VER 18 // current year, or date of c++2a ratification
# endif
#endif // _LIBCPP_STD_VER
#if defined(__ELF__)
# define _LIBCPP_OBJECT_FORMAT_ELF 1
#elif defined(__MACH__)
@ -462,6 +474,19 @@ namespace std {
}
}
#if _LIBCPP_STD_VER >= 17
#define _LIBCPP_BEGIN_NAMESPACE_FILESYSTEM \
_LIBCPP_BEGIN_NAMESPACE_STD inline namespace __fs { namespace filesystem {
#else
#define _LIBCPP_BEGIN_NAMESPACE_FILESYSTEM \
_LIBCPP_BEGIN_NAMESPACE_STD namespace __fs { namespace filesystem {
#endif
#define _LIBCPP_END_NAMESPACE_FILESYSTEM \
_LIBCPP_END_NAMESPACE_STD } }
#define _VSTD_FS _VSTD::__fs::filesystem
#if !defined(_LIBCPP_HAS_NO_ASAN) && !__has_feature(address_sanitizer)
#define _LIBCPP_HAS_NO_ASAN
#endif
@ -959,18 +984,6 @@ template <unsigned> struct __static_assert_check {};
#define _LIBCPP_WCTYPE_IS_MASK
#endif
#ifndef _LIBCPP_STD_VER
# if __cplusplus <= 201103L
# define _LIBCPP_STD_VER 11
# elif __cplusplus <= 201402L
# define _LIBCPP_STD_VER 14
# elif __cplusplus <= 201703L
# define _LIBCPP_STD_VER 17
# else
# define _LIBCPP_STD_VER 18 // current year, or date of c++2a ratification
# endif
#endif // _LIBCPP_STD_VER
#if _LIBCPP_STD_VER > 11
# define _LIBCPP_DEPRECATED [[deprecated]]
#else

View File

@ -52,8 +52,6 @@
#define _VSTD_CORO _VSTD_EXPERIMENTAL::coroutines_v1
#define _VSTD_FS ::std::experimental::filesystem::v1
#define _LIBCPP_BEGIN_NAMESPACE_EXPERIMENTAL_SIMD \
_LIBCPP_BEGIN_NAMESPACE_EXPERIMENTAL inline namespace parallelism_v2 {

File diff suppressed because it is too large Load Diff

2682
libcxx/include/filesystem Normal file

File diff suppressed because it is too large Load Diff

View File

@ -38,6 +38,7 @@ public:
bool is_open() const;
basic_filebuf* open(const char* s, ios_base::openmode mode);
basic_filebuf* open(const string& s, ios_base::openmode mode);
basic_filebuf* open(const filesystem::path& p, ios_base::openmode mode); // C++17
basic_filebuf* close();
protected:
@ -77,6 +78,8 @@ public:
basic_ifstream();
explicit basic_ifstream(const char* s, ios_base::openmode mode = ios_base::in);
explicit basic_ifstream(const string& s, ios_base::openmode mode = ios_base::in);
explicit basic_ifstream(const filesystem::path& p,
ios_base::openmode mode = ios_base::in); // C++17
basic_ifstream(basic_ifstream&& rhs);
basic_ifstream& operator=(basic_ifstream&& rhs);
@ -86,6 +89,8 @@ public:
bool is_open() const;
void open(const char* s, ios_base::openmode mode = ios_base::in);
void open(const string& s, ios_base::openmode mode = ios_base::in);
void open(const filesystem::path& s, ios_base::openmode mode = ios_base::in); // C++17
void close();
};
@ -110,6 +115,8 @@ public:
basic_ofstream();
explicit basic_ofstream(const char* s, ios_base::openmode mode = ios_base::out);
explicit basic_ofstream(const string& s, ios_base::openmode mode = ios_base::out);
explicit basic_ofstream(const filesystem::path& p,
ios_base::openmode mode = ios_base::out); // C++17
basic_ofstream(basic_ofstream&& rhs);
basic_ofstream& operator=(basic_ofstream&& rhs);
@ -119,6 +126,9 @@ public:
bool is_open() const;
void open(const char* s, ios_base::openmode mode = ios_base::out);
void open(const string& s, ios_base::openmode mode = ios_base::out);
void open(const filesystem::path& p,
ios_base::openmode mode = ios_base::out); // C++17
void close();
};
@ -143,6 +153,8 @@ public:
basic_fstream();
explicit basic_fstream(const char* s, ios_base::openmode mode = ios_base::in|ios_base::out);
explicit basic_fstream(const string& s, ios_base::openmode mode = ios_base::in|ios_base::out);
explicit basic_fstream(const filesystem::path& p,
ios_base::openmode mode = ios_base::in|ios_base::out); C++17
basic_fstream(basic_fstream&& rhs);
basic_fstream& operator=(basic_fstream&& rhs);
@ -152,6 +164,9 @@ public:
bool is_open() const;
void open(const char* s, ios_base::openmode mode = ios_base::in|ios_base::out);
void open(const string& s, ios_base::openmode mode = ios_base::in|ios_base::out);
void open(const filesystem::path& s,
ios_base::openmode mode = ios_base::in|ios_base::out); // C++17
void close();
};
@ -171,6 +186,7 @@ typedef basic_fstream<wchar_t> wfstream;
#include <__locale>
#include <cstdio>
#include <cstdlib>
#include <filesystem>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
@ -219,6 +235,12 @@ public:
_LIBCPP_INLINE_VISIBILITY
basic_filebuf* open(const string& __s, ios_base::openmode __mode);
#if _LIBCPP_STD_VER >= 17
_LIBCPP_INLINE_VISIBILITY
basic_filebuf* open(const _VSTD_FS::path& __p, ios_base::openmode __mode) {
return open(__p.c_str(), __mode);
}
#endif
_LIBCPP_INLINE_VISIBILITY
basic_filebuf* __open(int __fd, ios_base::openmode __mode);
#endif
@ -1128,6 +1150,11 @@ public:
#endif
_LIBCPP_INLINE_VISIBILITY
explicit basic_ifstream(const string& __s, ios_base::openmode __mode = ios_base::in);
#if _LIBCPP_STD_VER >= 17
_LIBCPP_INLINE_VISIBILITY
explicit basic_ifstream(const filesystem::path& __p, ios_base::openmode __mode = ios_base::in)
: basic_ifstream(__p.c_str(), __mode) {}
#endif // _LIBCPP_STD_VER >= 17
#endif
#ifndef _LIBCPP_CXX03_LANG
_LIBCPP_INLINE_VISIBILITY
@ -1149,6 +1176,13 @@ public:
void open(const wchar_t* __s, ios_base::openmode __mode = ios_base::in);
#endif
void open(const string& __s, ios_base::openmode __mode = ios_base::in);
#if _LIBCPP_STD_VER >= 17
_LIBCPP_INLINE_VISIBILITY
void open(const filesystem::path& __p,
ios_base::openmode __mode = ios_base::in) {
return open(__p.c_str(), __mode);
}
#endif // _LIBCPP_STD_VER >= 17
_LIBCPP_INLINE_VISIBILITY
void __open(int __fd, ios_base::openmode __mode);
@ -1329,6 +1363,13 @@ public:
#endif
_LIBCPP_INLINE_VISIBILITY
explicit basic_ofstream(const string& __s, ios_base::openmode __mode = ios_base::out);
#if _LIBCPP_STD_VER >= 17
_LIBCPP_INLINE_VISIBILITY
explicit basic_ofstream(const filesystem::path& __p, ios_base::openmode __mode = ios_base::out)
: basic_ofstream(__p.c_str(), __mode) {}
#endif // _LIBCPP_STD_VER >= 17
#ifndef _LIBCPP_CXX03_LANG
_LIBCPP_INLINE_VISIBILITY
basic_ofstream(basic_ofstream&& __rhs);
@ -1350,6 +1391,12 @@ public:
#endif
void open(const string& __s, ios_base::openmode __mode = ios_base::out);
#if _LIBCPP_STD_VER >= 17
_LIBCPP_INLINE_VISIBILITY
void open(const filesystem::path& __p, ios_base::openmode __mode = ios_base::out)
{ return open(__p.c_str(), __mode); }
#endif // _LIBCPP_STD_VER >= 17
_LIBCPP_INLINE_VISIBILITY
void __open(int __fd, ios_base::openmode __mode);
#endif
@ -1530,6 +1577,13 @@ public:
#endif
_LIBCPP_INLINE_VISIBILITY
explicit basic_fstream(const string& __s, ios_base::openmode __mode = ios_base::in | ios_base::out);
#if _LIBCPP_STD_VER >= 17
_LIBCPP_INLINE_VISIBILITY
explicit basic_fstream(const filesystem::path& __p, ios_base::openmode __mode = ios_base::in | ios_base::out)
: basic_fstream(__p.c_str(), __mode) {}
#endif // _LIBCPP_STD_VER >= 17
#endif
#ifndef _LIBCPP_CXX03_LANG
_LIBCPP_INLINE_VISIBILITY
@ -1551,6 +1605,13 @@ public:
void open(const wchar_t* __s, ios_base::openmode __mode = ios_base::in | ios_base::out);
#endif
void open(const string& __s, ios_base::openmode __mode = ios_base::in | ios_base::out);
#if _LIBCPP_STD_VER >= 17
_LIBCPP_INLINE_VISIBILITY
void open(const filesystem::path& __p, ios_base::openmode __mode = ios_base::in|ios_base::out)
{ return open(__p.c_str(), __mode); }
#endif // _LIBCPP_STD_VER >= 17
#endif
_LIBCPP_INLINE_VISIBILITY
void close();

View File

@ -264,6 +264,10 @@ module std [system] {
header "exception"
export *
}
module filesystem {
header "filesystem"
export *
}
module forward_list {
header "forward_list"
export initializer_list

View File

@ -291,12 +291,43 @@ endif()
# Add a meta-target for both libraries.
add_custom_target(cxx DEPENDS cxx-headers ${LIBCXX_BUILD_TARGETS})
if (LIBCXX_ENABLE_FILESYSTEM)
set(LIBCXX_FILESYSTEM_SOURCES
../src/filesystem/operations.cpp
../src/filesystem/directory_iterator.cpp)
# Filesystem uses __int128_t, which requires a definition of __muloi4 when
# compiled with UBSAN. This definition is not provided by libgcc_s, but is
# provided by compiler-rt. So we need to disable it to avoid having multiple
# definitions. See filesystem/int128_builtins.cpp.
if (NOT LIBCXX_USE_COMPILER_RT)
list(APPEND LIBCXX_FILESYSTEM_SOURCES ../src/filesystem/int128_builtins.cpp)
endif()
add_library(cxx_filesystem STATIC ${LIBCXX_FILESYSTEM_SOURCES})
if (LIBCXX_ENABLE_SHARED)
target_link_libraries(cxx_filesystem cxx_shared)
else()
target_link_libraries(cxx_filesystem cxx_static)
endif()
set(filesystem_flags "${LIBCXX_COMPILE_FLAGS}")
check_flag_supported(-std=c++14)
if (NOT MSVC AND LIBCXX_SUPPORTS_STD_EQ_CXX14_FLAG)
string(REPLACE "-std=c++11" "-std=c++14" filesystem_flags "${LIBCXX_COMPILE_FLAGS}")
endif()
set_target_properties(cxx_filesystem
PROPERTIES
COMPILE_FLAGS "${filesystem_flags}"
OUTPUT_NAME "c++fs"
)
endif()
if (LIBCXX_ENABLE_EXPERIMENTAL_LIBRARY)
file(GLOB LIBCXX_EXPERIMENTAL_SOURCES ../src/experimental/*.cpp)
if (LIBCXX_ENABLE_FILESYSTEM)
file(GLOB LIBCXX_FILESYSTEM_SOURCES ../src/experimental/filesystem/*.cpp)
endif()
add_library(cxx_experimental STATIC ${LIBCXX_EXPERIMENTAL_SOURCES} ${LIBCXX_FILESYSTEM_SOURCES})
add_library(cxx_experimental STATIC ${LIBCXX_EXPERIMENTAL_SOURCES})
if (LIBCXX_ENABLE_SHARED)
target_link_libraries(cxx_experimental cxx_shared)
else()
@ -315,6 +346,7 @@ if (LIBCXX_ENABLE_EXPERIMENTAL_LIBRARY)
)
endif()
if (LIBCXX_BUILD_EXTERNAL_THREAD_LIBRARY)
file(GLOB LIBCXX_EXTERNAL_THREADING_SUPPORT_SOURCES ../test/support/external_threads.cpp)
@ -362,10 +394,13 @@ if (LIBCXX_ENABLE_SHARED AND LIBCXX_ENABLE_ABI_LINKER_SCRIPT)
endif()
if (LIBCXX_INSTALL_LIBRARY)
if (LIBCXX_INSTALL_FILESYSTEM_LIBRARY)
set(filesystem_lib cxx_filesystem)
endif()
if (LIBCXX_INSTALL_EXPERIMENTAL_LIBRARY)
set(experimental_lib cxx_experimental)
endif()
install(TARGETS ${LIBCXX_INSTALL_TARGETS} ${experimental_lib}
install(TARGETS ${LIBCXX_INSTALL_TARGETS} ${filesystem_lib} ${experimental_lib}
LIBRARY DESTINATION ${LIBCXX_INSTALL_PREFIX}lib${LIBCXX_LIBDIR_SUFFIX} COMPONENT cxx
ARCHIVE DESTINATION ${LIBCXX_INSTALL_PREFIX}lib${LIBCXX_LIBDIR_SUFFIX} COMPONENT cxx
)
@ -385,6 +420,9 @@ if (NOT CMAKE_CONFIGURATION_TYPES AND (LIBCXX_INSTALL_LIBRARY OR
if(LIBCXX_INSTALL_LIBRARY)
set(lib_install_target cxx)
endif()
if (LIBCXX_INSTALL_FILESYSTEM_LIBRARY)
set(filesystem_lib_install_target cxx_filesystem)
endif()
if (LIBCXX_INSTALL_EXPERIMENTAL_LIBRARY)
set(experimental_lib_install_target cxx_experimental)
endif()
@ -394,6 +432,7 @@ if (NOT CMAKE_CONFIGURATION_TYPES AND (LIBCXX_INSTALL_LIBRARY OR
add_custom_target(install-cxx
DEPENDS ${lib_install_target}
${experimental_lib_install_target}
${filesystem_lib_install_target}
${header_install_target}
COMMAND "${CMAKE_COMMAND}"
-DCMAKE_INSTALL_COMPONENT=cxx
@ -401,6 +440,7 @@ if (NOT CMAKE_CONFIGURATION_TYPES AND (LIBCXX_INSTALL_LIBRARY OR
add_custom_target(install-cxx-stripped
DEPENDS ${lib_install_target}
${experimental_lib_install_target}
${filesystem_lib_install_target}
${header_install_target}
COMMAND "${CMAKE_COMMAND}"
-DCMAKE_INSTALL_COMPONENT=cxx

View File

@ -7,7 +7,7 @@
//
//===----------------------------------------------------------------------===//
#include "experimental/filesystem"
#include "filesystem"
#include "__config"
#if defined(_LIBCPP_WIN32API)
#define WIN32_LEAN_AND_MEAN
@ -19,14 +19,14 @@
#include "filesystem_common.h"
_LIBCPP_BEGIN_NAMESPACE_EXPERIMENTAL_FILESYSTEM
_LIBCPP_BEGIN_NAMESPACE_FILESYSTEM
namespace detail {
namespace {
#if !defined(_LIBCPP_WIN32API)
template <class DirEntT, class = decltype(DirEntT::d_type)>
static file_type get_file_type(DirEntT *ent, int) {
static file_type get_file_type(DirEntT* ent, int) {
switch (ent->d_type) {
case DT_BLK:
return file_type::block;
@ -52,22 +52,22 @@ static file_type get_file_type(DirEntT *ent, int) {
}
template <class DirEntT>
static file_type get_file_type(DirEntT *ent, long) {
static file_type get_file_type(DirEntT* ent, long) {
return file_type::none;
}
static pair<string_view, file_type>
posix_readdir(DIR *dir_stream, error_code& ec) {
struct dirent* dir_entry_ptr = nullptr;
errno = 0; // zero errno in order to detect errors
ec.clear();
if ((dir_entry_ptr = ::readdir(dir_stream)) == nullptr) {
if (errno)
ec = capture_errno();
return {};
} else {
return {dir_entry_ptr->d_name, get_file_type(dir_entry_ptr, 0)};
}
static pair<string_view, file_type> posix_readdir(DIR* dir_stream,
error_code& ec) {
struct dirent* dir_entry_ptr = nullptr;
errno = 0; // zero errno in order to detect errors
ec.clear();
if ((dir_entry_ptr = ::readdir(dir_stream)) == nullptr) {
if (errno)
ec = capture_errno();
return {};
} else {
return {dir_entry_ptr->d_name, get_file_type(dir_entry_ptr, 0)};
}
}
#else
@ -77,7 +77,7 @@ static file_type get_file_type(const WIN32_FIND_DATA& data) {
return file_type::unknown;
}
static uintmax_t get_file_size(const WIN32_FIND_DATA& data) {
return (data.nFileSizeHight * (MAXDWORD+1)) + data.nFileSizeLow;
return (data.nFileSizeHight * (MAXDWORD + 1)) + data.nFileSizeLow;
}
static file_time_type get_write_time(const WIN32_FIND_DATA& data) {
ULARGE_INTEGER tmp;
@ -97,19 +97,18 @@ using detail::ErrorHandler;
#if defined(_LIBCPP_WIN32API)
class __dir_stream {
public:
__dir_stream() = delete;
__dir_stream& operator=(const __dir_stream&) = delete;
__dir_stream(__dir_stream&& __ds) noexcept
: __stream_(__ds.__stream_), __root_(move(__ds.__root_)),
__entry_(move(__ds.__entry_)) {
__dir_stream(__dir_stream&& __ds) noexcept : __stream_(__ds.__stream_),
__root_(move(__ds.__root_)),
__entry_(move(__ds.__entry_)) {
__ds.__stream_ = INVALID_HANDLE_VALUE;
}
__dir_stream(const path& root, directory_options opts, error_code& ec)
: __stream_(INVALID_HANDLE_VALUE), __root_(root) {
__stream_ = ::FindFirstFileEx(root.c_str(), &__data_);
__stream_ = ::FindFirstFileEx(root.c_str(), &__data_);
if (__stream_ == INVALID_HANDLE_VALUE) {
ec = error_code(::GetLastError(), generic_category());
const bool ignore_permission_denied =
@ -166,75 +165,74 @@ public:
#else
class __dir_stream {
public:
__dir_stream() = delete;
__dir_stream& operator=(const __dir_stream&) = delete;
__dir_stream() = delete;
__dir_stream& operator=(const __dir_stream&) = delete;
__dir_stream(__dir_stream&& other) noexcept
: __stream_(other.__stream_), __root_(move(other.__root_)),
__entry_(move(other.__entry_))
{
other.__stream_ = nullptr;
__dir_stream(__dir_stream&& other) noexcept : __stream_(other.__stream_),
__root_(move(other.__root_)),
__entry_(move(other.__entry_)) {
other.__stream_ = nullptr;
}
__dir_stream(const path& root, directory_options opts, error_code& ec)
: __stream_(nullptr), __root_(root) {
if ((__stream_ = ::opendir(root.c_str())) == nullptr) {
ec = detail::capture_errno();
const bool allow_eacess =
bool(opts & directory_options::skip_permission_denied);
if (allow_eacess && ec.value() == EACCES)
ec.clear();
return;
}
advance(ec);
}
~__dir_stream() noexcept {
if (__stream_)
close();
}
__dir_stream(const path& root, directory_options opts, error_code& ec)
: __stream_(nullptr),
__root_(root)
{
if ((__stream_ = ::opendir(root.c_str())) == nullptr) {
ec = detail::capture_errno();
const bool allow_eacess =
bool(opts & directory_options::skip_permission_denied);
if (allow_eacess && ec.value() == EACCES)
ec.clear();
return;
}
advance(ec);
bool good() const noexcept { return __stream_ != nullptr; }
bool advance(error_code& ec) {
while (true) {
auto str_type_pair = detail::posix_readdir(__stream_, ec);
auto& str = str_type_pair.first;
if (str == "." || str == "..") {
continue;
} else if (ec || str.empty()) {
close();
return false;
} else {
__entry_.__assign_iter_entry(
__root_ / str,
directory_entry::__create_iter_result(str_type_pair.second));
return true;
}
}
}
~__dir_stream() noexcept
{ if (__stream_) close(); }
bool good() const noexcept { return __stream_ != nullptr; }
bool advance(error_code &ec) {
while (true) {
auto str_type_pair = detail::posix_readdir(__stream_, ec);
auto& str = str_type_pair.first;
if (str == "." || str == "..") {
continue;
} else if (ec || str.empty()) {
close();
return false;
} else {
__entry_.__assign_iter_entry(
__root_ / str,
directory_entry::__create_iter_result(str_type_pair.second));
return true;
}
}
}
private:
error_code close() noexcept {
error_code m_ec;
if (::closedir(__stream_) == -1)
m_ec = detail::capture_errno();
__stream_ = nullptr;
return m_ec;
}
error_code close() noexcept {
error_code m_ec;
if (::closedir(__stream_) == -1)
m_ec = detail::capture_errno();
__stream_ = nullptr;
return m_ec;
}
DIR* __stream_{nullptr};
DIR * __stream_{nullptr};
public:
path __root_;
directory_entry __entry_;
path __root_;
directory_entry __entry_;
};
#endif
// directory_iterator
directory_iterator::directory_iterator(const path& p, error_code *ec,
directory_options opts)
{
directory_iterator::directory_iterator(const path& p, error_code* ec,
directory_options opts) {
ErrorHandler<void> err("directory_iterator::directory_iterator(...)", ec, &p);
error_code m_ec;
@ -248,38 +246,35 @@ directory_iterator::directory_iterator(const path& p, error_code *ec,
}
}
directory_iterator& directory_iterator::__increment(error_code *ec)
{
_LIBCPP_ASSERT(__imp_, "Attempting to increment an invalid iterator");
ErrorHandler<void> err("directory_iterator::operator++()", ec);
error_code m_ec;
if (!__imp_->advance(m_ec)) {
path root = move(__imp_->__root_);
__imp_.reset();
if (m_ec)
err.report(m_ec, "at root \"%s\"", root);
}
return *this;
directory_iterator& directory_iterator::__increment(error_code* ec) {
_LIBCPP_ASSERT(__imp_, "Attempting to increment an invalid iterator");
ErrorHandler<void> err("directory_iterator::operator++()", ec);
error_code m_ec;
if (!__imp_->advance(m_ec)) {
path root = move(__imp_->__root_);
__imp_.reset();
if (m_ec)
err.report(m_ec, "at root \"%s\"", root);
}
return *this;
}
directory_entry const& directory_iterator::__dereference() const {
_LIBCPP_ASSERT(__imp_, "Attempting to dereference an invalid iterator");
return __imp_->__entry_;
_LIBCPP_ASSERT(__imp_, "Attempting to dereference an invalid iterator");
return __imp_->__entry_;
}
// recursive_directory_iterator
struct recursive_directory_iterator::__shared_imp {
stack<__dir_stream> __stack_;
directory_options __options_;
directory_options __options_;
};
recursive_directory_iterator::recursive_directory_iterator(const path& p,
directory_options opt, error_code *ec)
: __imp_(nullptr), __rec_(true)
{
recursive_directory_iterator::recursive_directory_iterator(
const path& p, directory_options opt, error_code* ec)
: __imp_(nullptr), __rec_(true) {
ErrorHandler<void> err("recursive_directory_iterator", ec, &p);
error_code m_ec;
@ -294,40 +289,40 @@ recursive_directory_iterator::recursive_directory_iterator(const path& p,
__imp_->__stack_.push(move(new_s));
}
void recursive_directory_iterator::__pop(error_code* ec)
{
_LIBCPP_ASSERT(__imp_, "Popping the end iterator");
if (ec) ec->clear();
__imp_->__stack_.pop();
if (__imp_->__stack_.size() == 0)
__imp_.reset();
else
__advance(ec);
void recursive_directory_iterator::__pop(error_code* ec) {
_LIBCPP_ASSERT(__imp_, "Popping the end iterator");
if (ec)
ec->clear();
__imp_->__stack_.pop();
if (__imp_->__stack_.size() == 0)
__imp_.reset();
else
__advance(ec);
}
directory_options recursive_directory_iterator::options() const {
return __imp_->__options_;
return __imp_->__options_;
}
int recursive_directory_iterator::depth() const {
return __imp_->__stack_.size() - 1;
return __imp_->__stack_.size() - 1;
}
const directory_entry& recursive_directory_iterator::__dereference() const {
return __imp_->__stack_.top().__entry_;
return __imp_->__stack_.top().__entry_;
}
recursive_directory_iterator&
recursive_directory_iterator::__increment(error_code *ec)
{
if (ec) ec->clear();
if (recursion_pending()) {
if (__try_recursion(ec) || (ec && *ec))
return *this;
}
__rec_ = true;
__advance(ec);
return *this;
recursive_directory_iterator::__increment(error_code* ec) {
if (ec)
ec->clear();
if (recursion_pending()) {
if (__try_recursion(ec) || (ec && *ec))
return *this;
}
__rec_ = true;
__advance(ec);
return *this;
}
void recursive_directory_iterator::__advance(error_code* ec) {
@ -344,16 +339,16 @@ void recursive_directory_iterator::__advance(error_code* ec) {
stack.pop();
}
if (m_ec) {
path root = move(stack.top().__root_);
__imp_.reset();
err.report(m_ec, "at root \"%s\"", root);
} else {
__imp_.reset();
}
if (m_ec) {
path root = move(stack.top().__root_);
__imp_.reset();
err.report(m_ec, "at root \"%s\"", root);
} else {
__imp_.reset();
}
}
bool recursive_directory_iterator::__try_recursion(error_code *ec) {
bool recursive_directory_iterator::__try_recursion(error_code* ec) {
ErrorHandler<void> err("recursive_directory_iterator::operator++()", ec);
bool rec_sym = bool(options() & directory_options::follow_directory_symlink);
@ -376,26 +371,26 @@ bool recursive_directory_iterator::__try_recursion(error_code *ec) {
skip_rec = true;
}
if (!skip_rec) {
__dir_stream new_it(curr_it.__entry_.path(), __imp_->__options_, m_ec);
if (new_it.good()) {
__imp_->__stack_.push(move(new_it));
return true;
}
if (!skip_rec) {
__dir_stream new_it(curr_it.__entry_.path(), __imp_->__options_, m_ec);
if (new_it.good()) {
__imp_->__stack_.push(move(new_it));
return true;
}
if (m_ec) {
const bool allow_eacess = bool(__imp_->__options_
& directory_options::skip_permission_denied);
if (m_ec.value() == EACCES && allow_eacess) {
if (ec) ec->clear();
} else {
path at_ent = move(curr_it.__entry_.__p_);
__imp_.reset();
err.report(m_ec, "attempting recursion into \"%s\"", at_ent);
}
}
if (m_ec) {
const bool allow_eacess =
bool(__imp_->__options_ & directory_options::skip_permission_denied);
if (m_ec.value() == EACCES && allow_eacess) {
if (ec)
ec->clear();
} else {
path at_ent = move(curr_it.__entry_.__p_);
__imp_.reset();
err.report(m_ec, "attempting recursion into \"%s\"", at_ent);
}
return false;
}
return false;
}
_LIBCPP_END_NAMESPACE_EXPERIMENTAL_FILESYSTEM
_LIBCPP_END_NAMESPACE_FILESYSTEM

View File

@ -10,7 +10,8 @@
#ifndef FILESYSTEM_COMMON_H
#define FILESYSTEM_COMMON_H
#include "experimental/__config"
#include "__config"
#include "filesystem"
#include "array"
#include "chrono"
#include "cstdlib"
@ -20,11 +21,9 @@
#include <sys/stat.h>
#include <sys/statvfs.h>
#include <sys/time.h> // for ::utimes as used in __last_write_time
#include <fcntl.h> /* values for fchmodat */
#include <fcntl.h> /* values for fchmodat */
#include <experimental/filesystem>
#include "../../include/apple_availability.h"
#include "../include/apple_availability.h"
#if !defined(__APPLE__)
// We can use the presence of UTIME_OMIT to detect platforms that provide
@ -39,7 +38,7 @@
#pragma GCC diagnostic ignored "-Wunused-function"
#endif
_LIBCPP_BEGIN_NAMESPACE_EXPERIMENTAL_FILESYSTEM
_LIBCPP_BEGIN_NAMESPACE_FILESYSTEM
namespace detail {
namespace {
@ -49,7 +48,7 @@ static string format_string_imp(const char* msg, ...) {
struct GuardVAList {
va_list& target;
bool active = true;
GuardVAList(va_list &target) : target(target), active(true) {}
GuardVAList(va_list& target) : target(target), active(true) {}
void clear() {
if (active)
va_end(target);
@ -386,10 +385,10 @@ TimeSpec extract_atime(StatT const& st) { return st.st_atim; }
// to use it.
bool posix_utimes(const path& p, std::array<TimeSpec, 2> const& TS,
error_code& ec) {
error_code& ec) {
using namespace chrono;
auto Convert = [](long nsec) {
using int_type = decltype(std::declval<::timeval>().tv_usec);
using int_type = decltype(std::declval< ::timeval>().tv_usec);
auto dur = duration_cast<microseconds>(nanoseconds(nsec)).count();
return static_cast<int_type>(dur);
};
@ -404,9 +403,8 @@ bool posix_utimes(const path& p, std::array<TimeSpec, 2> const& TS,
#if defined(_LIBCPP_USE_UTIMENSAT)
bool posix_utimensat(const path& p, std::array<TimeSpec, 2> const& TS,
error_code& ec) {
if (::utimensat(AT_FDCWD, p.c_str(), TS.data(), 0) == -1)
{
error_code& ec) {
if (::utimensat(AT_FDCWD, p.c_str(), TS.data(), 0) == -1) {
ec = capture_errno();
return true;
}
@ -423,10 +421,9 @@ bool set_file_times(const path& p, std::array<TimeSpec, 2> const& TS,
#endif
}
} // namespace
} // end namespace detail
_LIBCPP_END_NAMESPACE_EXPERIMENTAL_FILESYSTEM
_LIBCPP_END_NAMESPACE_FILESYSTEM
#endif // FILESYSTEM_COMMON_H

View File

@ -17,7 +17,7 @@
#include "__config"
#include "climits"
#ifndef _LIBCPP_HAS_NO_INT128
#if !defined(_LIBCPP_HAS_NO_INT128)
extern "C" __attribute__((no_sanitize("undefined")))
__int128_t __muloti4(__int128_t a, __int128_t b, int* overflow) {

View File

@ -62,6 +62,7 @@
#include <deque>
#include <errno.h>
#include <exception>
#include <filesystem>
#include <float.h>
#include <forward_list>
#include <fstream>

View File

@ -7,8 +7,6 @@
//
//===----------------------------------------------------------------------===//
// UNSUPPORTED: c++98, c++03
// <experimental/filesystem>
#include <experimental/filesystem>

View File

@ -9,11 +9,11 @@
// UNSUPPORTED: c++98, c++03
// <experimental/filesystem>
// <filesystem>
// class directory_entry
// RUN: %build -I%libcxx_src_root/src/experimental/filesystem
// RUN: %build -I%libcxx_src_root/src/filesystem
// RUN: %run
#include "filesystem_include.hpp"

View File

@ -13,13 +13,13 @@
// MODULES_DEFINES: _LIBCPP_DEBUG_USE_EXCEPTIONS
// MODULES_DEFINES: _LIBCPP_DEBUG=0
// <experimental/filesystem>
// <filesystem>
// class path
#define _LIBCPP_DEBUG 0
#define _LIBCPP_DEBUG_USE_EXCEPTIONS
#include <experimental/filesystem>
#include "filesystem_include.hpp"
#include <iterator>
#include <type_traits>
#include <cassert>
@ -27,8 +27,6 @@
#include "test_macros.h"
#include "filesystem_test_helper.hpp"
namespace fs = std::experimental::filesystem;
int main() {
using namespace fs;
using ExType = std::__libcpp_debug_exception;

View File

@ -9,16 +9,14 @@
// UNSUPPORTED: c++98, c++03
// <experimental/filesystem>
// <filesystem>
// class path
#include <experimental/filesystem>
#include "filesystem_include.hpp"
#include <iterator>
namespace fs = std::experimental::filesystem;
int main() {
using namespace fs;
using RIt = std::reverse_iterator<path::iterator>;

View File

@ -9,7 +9,7 @@
// UNSUPPORTED: c++98, c++03
// <experimental/filesystem>
// <filesystem>
// template <class Tp> struct __is_pathable
@ -21,7 +21,7 @@
// * A character array, which points to a NTCTS after array-to-pointer decay.
#include <experimental/filesystem>
#include "filesystem_include.hpp"
#include <type_traits>
#include <cassert>
@ -30,8 +30,6 @@
#include "min_allocator.h"
#include "constexpr_char_traits.hpp"
namespace fs = std::experimental::filesystem;
using fs::__is_pathable;
template <class Tp>

View File

@ -9,14 +9,14 @@
// UNSUPPORTED: c++98, c++03, c++11
// <experimental/filesystem>
// <filesystem>
// typedef TrivialClock file_time_type;
// RUN: %build -I%libcxx_src_root/src/experimental/filesystem
// RUN: %build -I%libcxx_src_root/src/filesystem
// RUN: %run
#include <experimental/filesystem>
#include <filesystem>
#include <chrono>
#include <type_traits>
#include <limits>
@ -30,7 +30,7 @@
#endif
using namespace std::chrono;
namespace fs = std::experimental::filesystem;
namespace fs = std::__fs::filesystem;
using fs::file_time_type;
using fs::detail::time_util;

View File

@ -0,0 +1,20 @@
//===----------------------------------------------------------------------===//
//
// The LLVM Compiler Infrastructure
//
// This file is dual licensed under the MIT and the University of Illinois Open
// Source Licenses. See LICENSE.TXT for details.
//
//===----------------------------------------------------------------------===//
// <filesystem>
#include <filesystem>
#ifndef _LIBCPP_VERSION
#error _LIBCPP_VERSION not defined
#endif
int main()
{
}

View File

@ -0,0 +1,56 @@
//===----------------------------------------------------------------------===//
//
// The LLVM Compiler Infrastructure
//
// This file is dual licensed under the MIT and the University of Illinois Open
// Source Licenses. See LICENSE.TXT for details.
//
//===----------------------------------------------------------------------===//
// UNSUPPORTED: c++98, c++03, c++11, c++14
// <fstream>
// basic_filebuf<charT,traits>* open(const filesystem::path& p, ios_base::openmode mode);
#include <fstream>
#include <filesystem>
#include <cassert>
#include "platform_support.h"
namespace fs = std::filesystem;
int main() {
fs::path p = get_temp_file_name();
{
std::filebuf f;
assert(f.open(p, std::ios_base::out) != 0);
assert(f.is_open());
assert(f.sputn("123", 3) == 3);
}
{
std::filebuf f;
assert(f.open(p, std::ios_base::in) != 0);
assert(f.is_open());
assert(f.sbumpc() == '1');
assert(f.sbumpc() == '2');
assert(f.sbumpc() == '3');
}
std::remove(p.c_str());
{
std::wfilebuf f;
assert(f.open(p, std::ios_base::out) != 0);
assert(f.is_open());
assert(f.sputn(L"123", 3) == 3);
}
{
std::wfilebuf f;
assert(f.open(p, std::ios_base::in) != 0);
assert(f.is_open());
assert(f.sbumpc() == L'1');
assert(f.sbumpc() == L'2');
assert(f.sbumpc() == L'3');
}
remove(p.c_str());
}

View File

@ -0,0 +1,49 @@
//===----------------------------------------------------------------------===//
//
// The LLVM Compiler Infrastructure
//
// This file is dual licensed under the MIT and the University of Illinois Open
// Source Licenses. See LICENSE.TXT for details.
//
//===----------------------------------------------------------------------===//
// UNSUPPORTED: c++98, c++03, c++11, c++14
// <fstream>
// plate <class charT, class traits = char_traits<charT> >
// class basic_fstream
// explicit basic_fstream(const filesystem::path& s,
// ios_base::openmode mode = ios_base::in|ios_base::out);
#include <fstream>
#include <filesystem>
#include <cassert>
#include "platform_support.h"
namespace fs = std::filesystem;
int main() {
fs::path p = get_temp_file_name();
{
std::fstream fs(p, std::ios_base::in | std::ios_base::out |
std::ios_base::trunc);
double x = 0;
fs << 3.25;
fs.seekg(0);
fs >> x;
assert(x == 3.25);
}
std::remove(p.c_str());
{
std::wfstream fs(p, std::ios_base::in | std::ios_base::out |
std::ios_base::trunc);
double x = 0;
fs << 3.25;
fs.seekg(0);
fs >> x;
assert(x == 3.25);
}
std::remove(p.c_str());
}

View File

@ -0,0 +1,52 @@
//===----------------------------------------------------------------------===//
//
// The LLVM Compiler Infrastructure
//
// This file is dual licensed under the MIT and the University of Illinois Open
// Source Licenses. See LICENSE.TXT for details.
//
//===----------------------------------------------------------------------===//
// UNSUPPORTED: c++98, c++03, c++11, c++14
// <fstream>
// plate <class charT, class traits = char_traits<charT> >
// class basic_fstream
// void open(const filesystem::path& s, ios_base::openmode mode = ios_base::in|ios_base::out);
#include <fstream>
#include <filesystem>
#include <cassert>
#include "platform_support.h"
int main() {
std::filesystem::path p = get_temp_file_name();
{
std::fstream stream;
assert(!stream.is_open());
stream.open(p,
std::ios_base::in | std::ios_base::out | std::ios_base::trunc);
assert(stream.is_open());
double x = 0;
stream << 3.25;
stream.seekg(0);
stream >> x;
assert(x == 3.25);
}
std::remove(p.c_str());
{
std::wfstream stream;
assert(!stream.is_open());
stream.open(p,
std::ios_base::in | std::ios_base::out | std::ios_base::trunc);
assert(stream.is_open());
double x = 0;
stream << 3.25;
stream.seekg(0);
stream >> x;
assert(x == 3.25);
}
std::remove(p.c_str());
}

View File

@ -0,0 +1,53 @@
//===----------------------------------------------------------------------===//
//
// The LLVM Compiler Infrastructure
//
// This file is dual licensed under the MIT and the University of Illinois Open
// Source Licenses. See LICENSE.TXT for details.
//
//===----------------------------------------------------------------------===//
// UNSUPPORTED: c++98, c++03, c++11, c++14
// <fstream>
// template <class charT, class traits = char_traits<charT> >
// class basic_ifstream
// explicit basic_ifstream(const filesystem::path& s,
// ios_base::openmode mode = ios_base::in);
#include <fstream>
#include <filesystem>
#include <cassert>
namespace fs = std::filesystem;
int main() {
{
fs::path p;
static_assert(!std::is_convertible<fs::path, std::ifstream>::value,
"ctor should be explicit");
static_assert(std::is_constructible<std::ifstream, fs::path const&,
std::ios_base::openmode>::value,
"");
}
{
std::ifstream fs(fs::path("test.dat"));
double x = 0;
fs >> x;
assert(x == 3.25);
}
// std::ifstream(const fs::path&, std::ios_base::openmode) is tested in
// test/std/input.output/file.streams/fstreams/ofstream.cons/string.pass.cpp
// which creates writable files.
{
std::wifstream fs(fs::path("test.dat"));
double x = 0;
fs >> x;
assert(x == 3.25);
}
// std::wifstream(const fs::path&, std::ios_base::openmode) is tested in
// test/std/input.output/file.streams/fstreams/ofstream.cons/string.pass.cpp
// which creates writable files.
}

View File

@ -0,0 +1,48 @@
//===----------------------------------------------------------------------===//
//
// The LLVM Compiler Infrastructure
//
// This file is dual licensed under the MIT and the University of Illinois Open
// Source Licenses. See LICENSE.TXT for details.
//
//===----------------------------------------------------------------------===//
// UNSUPPORTED: c++98, c++03, c++11, c++14
// <fstream>
// template <class charT, class traits = char_traits<charT> >
// class basic_ifstream
// void open(const filesystem::path& s, ios_base::openmode mode = ios_base::in);
#include <fstream>
#include <filesystem>
#include <cassert>
int main() {
{
std::ifstream fs;
assert(!fs.is_open());
char c = 'a';
fs >> c;
assert(fs.fail());
assert(c == 'a');
fs.open(std::filesystem::path("test.dat"));
assert(fs.is_open());
fs >> c;
assert(c == 'r');
}
{
std::wifstream fs;
assert(!fs.is_open());
wchar_t c = L'a';
fs >> c;
assert(fs.fail());
assert(c == L'a');
fs.open(std::filesystem::path("test.dat"));
assert(fs.is_open());
fs >> c;
assert(c == L'r');
}
}

View File

@ -0,0 +1,69 @@
//===----------------------------------------------------------------------===//
//
// The LLVM Compiler Infrastructure
//
// This file is dual licensed under the MIT and the University of Illinois Open
// Source Licenses. See LICENSE.TXT for details.
//
//===----------------------------------------------------------------------===//
// UNSUPPORTED: c++98, c++03, c++11, c++14
// <fstream>
// plate <class charT, class traits = char_traits<charT> >
// class basic_ofstream
// explicit basic_ofstream(const filesystem::path& s, ios_base::openmode mode = ios_base::out);
#include <fstream>
#include <filesystem>
#include <cassert>
#include "platform_support.h"
namespace fs = std::filesystem;
int main() {
fs::path p = get_temp_file_name();
{
static_assert(!std::is_convertible<fs::path, std::ofstream>::value,
"ctor should be explicit");
static_assert(std::is_constructible<std::ofstream, fs::path const&,
std::ios_base::openmode>::value,
"");
}
{
std::ofstream stream(p);
stream << 3.25;
}
{
std::ifstream stream(p);
double x = 0;
stream >> x;
assert(x == 3.25);
}
{
std::ifstream stream(p, std::ios_base::out);
double x = 0;
stream >> x;
assert(x == 3.25);
}
std::remove(p.c_str());
{
std::wofstream stream(p);
stream << 3.25;
}
{
std::wifstream stream(p);
double x = 0;
stream >> x;
assert(x == 3.25);
}
{
std::wifstream stream(p, std::ios_base::out);
double x = 0;
stream >> x;
assert(x == 3.25);
}
std::remove(p.c_str());
}

View File

@ -0,0 +1,62 @@
//===----------------------------------------------------------------------===//
//
// The LLVM Compiler Infrastructure
//
// This file is dual licensed under the MIT and the University of Illinois Open
// Source Licenses. See LICENSE.TXT for details.
//
//===----------------------------------------------------------------------===//
// UNSUPPORTED: c++98, c++03, c++11, c++14
// <fstream>
// plate <class charT, class traits = char_traits<charT> >
// class basic_ofstream
// void open(const filesystem::path& s, ios_base::openmode mode = ios_base::out);
#include <fstream>
#include <filesystem>
#include <cassert>
#include "platform_support.h"
namespace fs = std::filesystem;
int main() {
fs::path p = get_temp_file_name();
{
std::ofstream fs;
assert(!fs.is_open());
char c = 'a';
fs << c;
assert(fs.fail());
fs.open(p);
assert(fs.is_open());
fs << c;
}
{
std::ifstream fs(p.c_str());
char c = 0;
fs >> c;
assert(c == 'a');
}
std::remove(p.c_str());
{
std::wofstream fs;
assert(!fs.is_open());
wchar_t c = L'a';
fs << c;
assert(fs.fail());
fs.open(p);
assert(fs.is_open());
fs << c;
}
{
std::wifstream fs(p.c_str());
wchar_t c = 0;
fs >> c;
assert(c == L'a');
}
std::remove(p.c_str());
}

View File

@ -10,7 +10,7 @@
// UNSUPPORTED: c++98, c++03
// XFAIL: apple-clang-7, clang-3.7, clang-3.8
// <experimental/filesystem>
// <filesystem>
// class directory_entry

View File

@ -9,7 +9,7 @@
// UNSUPPORTED: c++98, c++03
// <experimental/filesystem>
// <filesystem>
// class directory_iterator

View File

@ -9,7 +9,7 @@
// UNSUPPORTED: c++98, c++03
// <experimental/filesystem>
// <filesystem>
// class file_status

View File

@ -9,7 +9,7 @@
// UNSUPPORTED: c++98, c++03
// <experimental/filesystem>
// <filesystem>
// class file_status

View File

@ -9,7 +9,7 @@
// UNSUPPORTED: c++98, c++03
// <experimental/filesystem>
// <filesystem>
// class file_status

View File

@ -9,7 +9,7 @@
// UNSUPPORTED: c++98, c++03
// <experimental/filesystem>
// <filesystem>
// class path

View File

@ -9,7 +9,7 @@
// UNSUPPORTED: c++98, c++03
// <experimental/filesystem>
// <filesystem>
// class path

View File

@ -9,7 +9,7 @@
// UNSUPPORTED: c++98, c++03
// <experimental/filesystem>
// <filesystem>
// class path

View File

@ -9,7 +9,7 @@
// UNSUPPORTED: c++98, c++03
// <experimental/filesystem>
// <filesystem>
// class path

View File

@ -8,7 +8,7 @@
//
//===----------------------------------------------------------------------===//
// <experimental/filesystem>
// <filesystem>
// class path

Some files were not shown because too many files have changed in this diff Show More