From 998a5c88312066fcc2b2de1358edc76587611354 Mon Sep 17 00:00:00 2001 From: Eric Fiselier Date: Fri, 27 Jul 2018 03:07:09 +0000 Subject: Implement This patch implements the header and uses that to provide . Unlike other standard headers, the symbols needed for 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 , which now requires linking libc++fs). The reason for keeping 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 , 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 --- .../path.member/path.native.obs/native.pass.cpp | 39 ---------------------- 1 file changed, 39 deletions(-) delete mode 100644 libcxx/test/std/experimental/filesystem/class.path/path.member/path.native.obs/native.pass.cpp (limited to 'libcxx/test/std/experimental/filesystem/class.path/path.member/path.native.obs/native.pass.cpp') diff --git a/libcxx/test/std/experimental/filesystem/class.path/path.member/path.native.obs/native.pass.cpp b/libcxx/test/std/experimental/filesystem/class.path/path.member/path.native.obs/native.pass.cpp deleted file mode 100644 index 35ea4934623..00000000000 --- a/libcxx/test/std/experimental/filesystem/class.path/path.member/path.native.obs/native.pass.cpp +++ /dev/null @@ -1,39 +0,0 @@ -//===----------------------------------------------------------------------===// -// -// 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 - -// - -// class path - -// const string_type& native() const noexcept; - -#include "filesystem_include.hpp" -#include -#include - -#include "test_macros.h" -#include "filesystem_test_helper.hpp" - - -int main() -{ - using namespace fs; - const char* const value = "hello world"; - { // Check signature - path p(value); - ASSERT_SAME_TYPE(path::string_type const&, decltype(p.native())); - ASSERT_NOEXCEPT(p.native()); - } - { // native() is tested elsewhere - path p(value); - assert(p.native() == value); - } -} -- cgit v1.2.3