svn commit: r321190 - in vendor/libc++/dist: docs/DesignDocs include lib test/support www

Dimitry Andric dim at FreeBSD.org
Wed Jul 19 07:02:51 UTC 2017


Author: dim
Date: Wed Jul 19 07:02:49 2017
New Revision: 321190
URL: https://svnweb.freebsd.org/changeset/base/321190

Log:
  Vendor import of libc++ trunk r308421:
  https://llvm.org/svn/llvm-project/libcxx/trunk@308421

Added:
  vendor/libc++/dist/www/cxx2a_status.html   (contents, props changed)
Modified:
  vendor/libc++/dist/docs/DesignDocs/VisibilityMacros.rst
  vendor/libc++/dist/include/__config
  vendor/libc++/dist/include/algorithm
  vendor/libc++/dist/include/string
  vendor/libc++/dist/include/vector
  vendor/libc++/dist/lib/CMakeLists.txt
  vendor/libc++/dist/test/support/test_macros.h
  vendor/libc++/dist/www/cxx1z_status.html
  vendor/libc++/dist/www/index.html
  vendor/libc++/dist/www/upcoming_meeting.html

Modified: vendor/libc++/dist/docs/DesignDocs/VisibilityMacros.rst
==============================================================================
--- vendor/libc++/dist/docs/DesignDocs/VisibilityMacros.rst	Wed Jul 19 07:02:46 2017	(r321189)
+++ vendor/libc++/dist/docs/DesignDocs/VisibilityMacros.rst	Wed Jul 19 07:02:49 2017	(r321190)
@@ -90,20 +90,21 @@ Visibility Macros
   The macro has an empty definition with GCC.
 
   **Windows Behavior**: `extern template` and `dllexport` are fundamentally
-  incompatible *on a template class* on Windows; the former suppresses
+  incompatible *on a class template* on Windows; the former suppresses
   instantiation, while the latter forces it. Specifying both on the same
-  declaration makes the template class be instantiated, which is not desirable
+  declaration makes the class template be instantiated, which is not desirable
   inside headers. This macro therefore expands to `dllimport` outside of libc++
   but nothing inside of it (rather than expanding to `dllexport`); instead, the
   explicit instantiations themselves are marked as exported. Note that this
-  applies *only* to extern template *classes*. Extern template *functions* obey
+  applies *only* to extern *class* templates. Extern *function* templates obey
   regular import/export semantics, and applying `dllexport` directly to the
-  extern template declaration is the correct thing to do for them.
+  extern template declaration (i.e. using `_LIBCPP_FUNC_VIS`) is the correct
+  thing to do for them.
 
 **_LIBCPP_CLASS_TEMPLATE_INSTANTIATION_VIS**
   Mark the member functions, typeinfo, and vtable of an explicit instantiation
   of a class template as being exported by the libc++ library. This attribute
-  must be specified on all template class explicit instantiations.
+  must be specified on all class template explicit instantiations.
 
   It is only necessary to mark the explicit instantiation itself (as opposed to
   the extern template declaration) as exported on Windows, as discussed above.

Modified: vendor/libc++/dist/include/__config
==============================================================================
--- vendor/libc++/dist/include/__config	Wed Jul 19 07:02:46 2017	(r321189)
+++ vendor/libc++/dist/include/__config	Wed Jul 19 07:02:49 2017	(r321190)
@@ -229,8 +229,9 @@
 #  define _LIBCPP_SHORT_WCHAR   1
 // Both MinGW and native MSVC provide a "MSVC"-like enviroment
 #  define _LIBCPP_MSVCRT_LIKE
-// If mingw not explicitly detected, assume using MS C runtime only.
-#  ifndef __MINGW32__
+// If mingw not explicitly detected, assume using MS C runtime only if
+// a MS compatibility version is specified.
+#  if defined(_MSC_VER) && !defined(__MINGW32__)
 #    define _LIBCPP_MSVCRT // Using Microsoft's C Runtime library
 #  endif
 #  if (defined(_M_AMD64) || defined(__x86_64__)) || (defined(_M_ARM) || defined(__arm__))
@@ -625,7 +626,6 @@ namespace std {
 #define _LIBCPP_HIDDEN
 #define _LIBCPP_METHOD_TEMPLATE_IMPLICIT_INSTANTIATION_VIS
 #define _LIBCPP_TEMPLATE_VIS
-#define _LIBCPP_FUNC_VIS_ONLY
 #define _LIBCPP_ENUM_VIS
 
 #if defined(_LIBCPP_COMPILER_MSVC)
@@ -684,10 +684,6 @@ namespace std {
 #  endif
 #endif
 
-#ifndef _LIBCPP_FUNC_VIS_ONLY
-# define _LIBCPP_FUNC_VIS_ONLY _LIBCPP_FUNC_VIS
-#endif
-
 #ifndef _LIBCPP_EXTERN_VIS
 # define _LIBCPP_EXTERN_VIS
 #endif
@@ -925,8 +921,10 @@ template <unsigned> struct __static_assert_check {};
 #    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 16  // current year, or date of c++17 ratification
+#    define _LIBCPP_STD_VER 18  // current year, or date of c++2a ratification
 #  endif
 #endif  // _LIBCPP_STD_VER
 

Modified: vendor/libc++/dist/include/algorithm
==============================================================================
--- vendor/libc++/dist/include/algorithm	Wed Jul 19 07:02:46 2017	(r321189)
+++ vendor/libc++/dist/include/algorithm	Wed Jul 19 07:02:49 2017	(r321190)
@@ -4234,10 +4234,6 @@ sort(__wrap_iter<_Tp*> __first, __wrap_iter<_Tp*> __la
     _VSTD::sort<_Tp*, _Comp_ref>(__first.base(), __last.base(), __comp);
 }
 
-#ifdef _LIBCPP_MSVC
-#pragma warning( push )
-#pragma warning( disable: 4231)
-#endif // _LIBCPP_MSVC
 _LIBCPP_EXTERN_TEMPLATE(_LIBCPP_FUNC_VIS void __sort<__less<char>&, char*>(char*, char*, __less<char>&))
 _LIBCPP_EXTERN_TEMPLATE(_LIBCPP_FUNC_VIS void __sort<__less<wchar_t>&, wchar_t*>(wchar_t*, wchar_t*, __less<wchar_t>&))
 _LIBCPP_EXTERN_TEMPLATE(_LIBCPP_FUNC_VIS void __sort<__less<signed char>&, signed char*>(signed char*, signed char*, __less<signed char>&))
@@ -4271,9 +4267,6 @@ _LIBCPP_EXTERN_TEMPLATE(_LIBCPP_FUNC_VIS bool __insert
 _LIBCPP_EXTERN_TEMPLATE(_LIBCPP_FUNC_VIS bool __insertion_sort_incomplete<__less<long double>&, long double*>(long double*, long double*, __less<long double>&))
 
 _LIBCPP_EXTERN_TEMPLATE(_LIBCPP_FUNC_VIS unsigned __sort5<__less<long double>&, long double*>(long double*, long double*, long double*, long double*, long double*, __less<long double>&))
-#ifdef _LIBCPP_MSVC
-#pragma warning( pop )
-#endif  // _LIBCPP_MSVC
 
 // lower_bound
 

Modified: vendor/libc++/dist/include/string
==============================================================================
--- vendor/libc++/dist/include/string	Wed Jul 19 07:02:46 2017	(r321189)
+++ vendor/libc++/dist/include/string	Wed Jul 19 07:02:49 2017	(r321190)
@@ -578,14 +578,7 @@ __basic_string_common<__b>::__throw_out_of_range() con
     _VSTD::__throw_out_of_range("basic_string");
 }
 
-#ifdef _LIBCPP_MSVC
-#pragma warning( push )
-#pragma warning( disable: 4231 )
-#endif // _LIBCPP_MSVC
 _LIBCPP_EXTERN_TEMPLATE(class _LIBCPP_EXTERN_TEMPLATE_TYPE_VIS __basic_string_common<true>)
-#ifdef _LIBCPP_MSVC
-#pragma warning( pop )
-#endif // _LIBCPP_MSVC
 
 #ifdef _LIBCPP_NO_EXCEPTIONS
 template <class _Iter>
@@ -4006,7 +3999,7 @@ basic_string<_CharT, _Traits, _Allocator>::__subscript
 
 _LIBCPP_EXTERN_TEMPLATE(class _LIBCPP_EXTERN_TEMPLATE_TYPE_VIS basic_string<char>)
 _LIBCPP_EXTERN_TEMPLATE(class _LIBCPP_EXTERN_TEMPLATE_TYPE_VIS basic_string<wchar_t>)
-_LIBCPP_EXTERN_TEMPLATE(string operator+<char, char_traits<char>, allocator<char> >(char const*, string const&))
+_LIBCPP_EXTERN_TEMPLATE(_LIBCPP_FUNC_VIS string operator+<char, char_traits<char>, allocator<char> >(char const*, string const&))
 
 #if _LIBCPP_STD_VER > 11 
 // Literal suffixes for basic_string [basic.string.literals]

Modified: vendor/libc++/dist/include/vector
==============================================================================
--- vendor/libc++/dist/include/vector	Wed Jul 19 07:02:46 2017	(r321189)
+++ vendor/libc++/dist/include/vector	Wed Jul 19 07:02:49 2017	(r321190)
@@ -310,14 +310,7 @@ __vector_base_common<__b>::__throw_out_of_range() cons
     _VSTD::__throw_out_of_range("vector");
 }
 
-#ifdef _LIBCPP_MSVC
-#pragma warning( push )
-#pragma warning( disable: 4231 )
-#endif // _LIBCPP_MSVC
 _LIBCPP_EXTERN_TEMPLATE(class _LIBCPP_EXTERN_TEMPLATE_TYPE_VIS __vector_base_common<true>)
-#ifdef _LIBCPP_MSVC
-#pragma warning( pop )
-#endif // _LIBCPP_MSVC
 
 template <class _Tp, class _Allocator>
 class __vector_base

Modified: vendor/libc++/dist/lib/CMakeLists.txt
==============================================================================
--- vendor/libc++/dist/lib/CMakeLists.txt	Wed Jul 19 07:02:46 2017	(r321189)
+++ vendor/libc++/dist/lib/CMakeLists.txt	Wed Jul 19 07:02:49 2017	(r321190)
@@ -258,7 +258,7 @@ if (LIBCXX_ENABLE_STATIC)
       set(MERGE_ARCHIVES_SEARCH_PATHS "-L${LIBCXX_CXX_ABI_LIBRARY_PATH}")
     endif()
     if ((TARGET ${LIBCXX_CXX_ABI_LIBRARY}) OR
-        (${LIBCXX_CXX_ABI_LIBRARY} STREQUAL "cxxabi(_static|_shared)?" AND HAVE_LIBCXXABI))
+        (${LIBCXX_CXX_ABI_LIBRARY} MATCHES "cxxabi(_static|_shared)?" AND HAVE_LIBCXXABI))
       set(MERGE_ARCHIVES_ABI_TARGET "$<TARGET_LINKER_FILE:${LIBCXX_CXX_ABI_LIBRARY}>")
     else()
       set(MERGE_ARCHIVES_ABI_TARGET

Modified: vendor/libc++/dist/test/support/test_macros.h
==============================================================================
--- vendor/libc++/dist/test/support/test_macros.h	Wed Jul 19 07:02:46 2017	(r321189)
+++ vendor/libc++/dist/test/support/test_macros.h	Wed Jul 19 07:02:49 2017	(r321190)
@@ -81,8 +81,11 @@
 # define TEST_STD_VER 11
 #elif __cplusplus <= 201402L
 # define TEST_STD_VER 14
+#elif __cplusplus <= 201703L
+# define TEST_STD_VER 17
 #else
-# define TEST_STD_VER 16    // current year; greater than current standard
+# define TEST_STD_VER 99    // greater than current standard
+// This is deliberately different than _LIBCPP_STD_VER to discourage matching them up.
 #endif
 #endif
 

Modified: vendor/libc++/dist/www/cxx1z_status.html
==============================================================================
--- vendor/libc++/dist/www/cxx1z_status.html	Wed Jul 19 07:02:46 2017	(r321189)
+++ vendor/libc++/dist/www/cxx1z_status.html	Wed Jul 19 07:02:49 2017	(r321190)
@@ -161,6 +161,9 @@
 	<tr><td><a href="http://wg21.link/P0607R0">P0607R0</a></td><td>LWG</td><td>Inline Variables for the Standard Library</td><td>Kona</td><td></td><td></td></tr>
 	<tr><td><a href="http://wg21.link/P0618R0">P0618R0</a></td><td>LWG</td><td>Deprecating <codecvt></td><td>Kona</td><td></td><td></td></tr>
 	<tr><td><a href="http://wg21.link/P0623R0">P0623R0</a></td><td>LWG</td><td>Final C++17 Parallel Algorithms Fixes</td><td>Kona</td><td></td><td></td></tr>
+  	<tr><td></td><td></td><td></td><td></td><td></td><td></td></tr>
+	<tr><td><a href="http://wg21.link/P0682R1">P0682R1</a></td><td>LWG</td><td>Repairing elementary string conversions</td><td>Toronto</td><td></td><td></td></tr>
+	<tr><td><a href="http://wg21.link/P0739R0">P0739R0</a></td><td>LWG</td><td>Some improvements to class template argument deduction integration into the standard library</td><td>Toronto</td><td></td><td></td></tr>
 
 <!--  	<tr><td></td><td></td><td></td><td></td><td></td><td></td></tr> -->
   </table>
@@ -483,6 +486,11 @@
 	<tr><td><a href="http://wg21.link/LWG2911">2911</a></td><td>An is_aggregate type trait is needed</td><td>Kona</td><td>Complete</td></tr>
 	<tr><td><a href="http://wg21.link/LWG2921">2921</a></td><td>packaged_task and type-erased allocators</td><td>Kona</td><td></td></tr>
 	<tr><td><a href="http://wg21.link/LWG2934">2934</a></td><td>optional<const T> doesn't compare with T</td><td>Kona</td><td>Complete</td></tr>
+ 	<tr><td></td><td></td><td></td><td></td></tr>
+	<tr><td><a href="http://wg21.link/LWG2901">2901</a></td><td>Variants cannot properly support allocators</td><td>Toronto</td><td>Complete</td></tr>
+	<tr><td><a href="http://wg21.link/LWG2955">2955</a></td><td><tt>to_chars / from_chars</tt> depend on <tt>std::string</tt></td><td>Toronto</td><td>Resolved by <a href="https://wg21.link/P0682R1">P0682R1</a></td></tr>
+	<tr><td><a href="http://wg21.link/LWG2956">2956</a></td><td><tt>filesystem::canonical()</tt> still defined in terms of <tt>absolute(p, base)</tt></td><td>Toronto</td><td>Complete</td></tr>
+
 <!--
 	<tr><td><a href="http://wg21.link/LWG1214">1214</a></td><td>Insufficient/inconsistent key immutability requirements for associative containers</td><td>Urbana</td><td></td></tr>
 -->

Added: vendor/libc++/dist/www/cxx2a_status.html
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ vendor/libc++/dist/www/cxx2a_status.html	Wed Jul 19 07:02:49 2017	(r321190)
@@ -0,0 +1,90 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
+          "http://www.w3.org/TR/html4/strict.dtd">
+<!-- Material used from: HTML 4.01 specs: http://www.w3.org/TR/html401/ -->
+<html>
+<head>
+  <meta http-equiv="content-type" content="text/html; charset=utf-8">
+  <title>libc++ C++2a Status</title>
+  <link type="text/css" rel="stylesheet" href="menu.css">
+  <link type="text/css" rel="stylesheet" href="content.css">
+</head>
+
+<body>
+<div id="menu">
+  <div>
+    <a href="http://llvm.org/">LLVM Home</a>
+  </div>
+
+  <div class="submenu">
+    <label>libc++ Info</label>
+    <a href="/index.html">About</a>
+  </div>
+
+  <div class="submenu">
+    <label>Quick Links</label>
+    <a href="http://lists.llvm.org/mailman/listinfo/cfe-dev">cfe-dev</a>
+    <a href="http://lists.llvm.org/mailman/listinfo/cfe-commits">cfe-commits</a>
+    <a href="https://bugs.llvm.org/">Bug Reports</a>
+    <a href="http://llvm.org/svn/llvm-project/libcxx/trunk/">Browse SVN</a>
+    <a href="http://llvm.org/viewvc/llvm-project/libcxx/trunk/">Browse ViewVC</a>
+  </div>
+</div>
+
+<div id="content">
+  <!--*********************************************************************-->
+  <h1>libc++ C++2a Status</h1>
+  <!--*********************************************************************-->
+
+  <p>In July 2017, the C++ standard committee created a draft for the next version of the C++ standard, known here as "C++2a" (probably to be C++20).</p>
+  <p>This page shows the status of libc++; the status of clang's support of the language features is <a href="http://clang.llvm.org/cxx_status.html#cxx2a">here</a>.</p>
+
+  <p>The groups that have contributed papers:
+  <ul>
+    <li>LWG - Library working group</li>
+    <li>CWG - Core Language Working group</li>
+    <li>SG1 - Study group #1 (Concurrency working group)</li>
+  </ul>
+  </p>
+
+  <h3>Paper Status</h3>
+  <table id="papers" border="1">
+	<tr><th>Paper #</th><th>Group</th><th>Paper Name</th><th>Meeting</th><th>Status</th><th>First released version</th></tr>
+<!--
+	<tr><td><a href="http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2012/n3346.pdf">3346</a></td><td>LWG</td><td>Terminology for Container Element Requirements - Rev 1</td><td>Kona</td><td>Complete</td><td>3.4</td></tr>
+-->
+	<tr><td><a href="https://wg21.link/P0463R1">P0463R1</a></td><td>LWG</td><td>Endian just Endian</td><td>Toronto</td><td></td><td></td></tr>
+	<tr><td><a href="https://wg21.link/P0674R1">P0674R1</a></td><td>LWG</td><td>Extending make_shared to Support Arrays</td><td>Toronto</td><td></td><td></td></tr>
+
+<!--  	<tr><td></td><td></td><td></td><td></td><td></td><td></td></tr> -->
+  </table>
+
+<p><i>[ Note: "Nothing to do" means that no library changes were needed to implement this change -- end note]</i></p>
+
+  <h3>Library Working group Issues Status</h3>
+<!--   <I>Note: "NAD" means that the issue was deemed "Not a defect"</I> -->
+  <table id="issues" border="1">
+	<tr><th>Issue #</th><th>Issue Name</th><th>Meeting</th><th>Status</th></tr>
+<!--
+	<tr><td><a href="http://wg21.link/LWG1214">1214</a></td><td>Insufficient/inconsistent key immutability requirements for associative containers</td><td>Urbana</td><td></td></tr>
+-->
+	<tr><td><a href="http://wg21.link/LWG2070">2070</a></td><td><tt>allocate_shared</tt> should use <tt>allocator_traits<A>::construct</tt></td><td>Toronto</td><td>Resolved by <a href="https://wg21.link/P0674R1">P0674R1</a></td></tr>
+	<tr><td><a href="http://wg21.link/LWG2444">2444</a></td><td>Inconsistent complexity for <tt>std::sort_heap</tt></td><td>Toronto</td><td></td></tr>
+	<tr><td><a href="http://wg21.link/LWG2593">2593</a></td><td>Moved-from state of Allocators</td><td>Toronto</td><td></td></tr>
+	<tr><td><a href="http://wg21.link/LWG2597">2597</a></td><td><tt>std::log</tt> misspecified for complex numbers</td><td>Toronto</td><td></td></tr>
+	<tr><td><a href="http://wg21.link/LWG2783">2783</a></td><td><tt>stack::emplace()</tt> and <tt>queue::emplace()</tt> should return <tt>decltype(auto)</tt></td><td>Toronto</td><td></td></tr>
+	<tr><td><a href="http://wg21.link/LWG2932">2932</a></td><td>Constraints on parallel algorithm implementations are underspecified</td><td>Toronto</td><td></td></tr>
+	<tr><td><a href="http://wg21.link/LWG2937">2937</a></td><td>Is <tt>equivalent("existing_thing", "not_existing_thing")</tt> an error</td><td>Toronto</td><td>Complete</td></tr>
+	<tr><td><a href="http://wg21.link/LWG2940">2940</a></td><td><tt>result_of</tt> specification also needs a little cleanup</td><td>Toronto</td><td></td></tr>
+	<tr><td><a href="http://wg21.link/LWG2942">2942</a></td><td>LWG 2873's resolution missed <tt>weak_ptr::owner_before</tt></td><td>Toronto</td><td></td></tr>
+	<tr><td><a href="http://wg21.link/LWG2954">2954</a></td><td>Specialization of the convenience variable templates should be prohibited</td><td>Toronto</td><td></td></tr>
+	<tr><td><a href="http://wg21.link/LWG2961">2961</a></td><td>Bad postcondition for <tt>set_default_resource</tt></td><td>Toronto</td><td></td></tr>
+	<tr><td><a href="http://wg21.link/LWG2966">2966</a></td><td>Incomplete resolution of US 74</td><td>Toronto</td><td><i>Nothing to do</i></td></tr>
+	<tr><td><a href="http://wg21.link/LWG2974">2974</a></td><td>Diagnose out of bounds <tt>tuple_element/variant_alternative</tt></td><td>Toronto</td><td>Complete</td></tr>
+
+<!-- 	<tr><td></td><td></td><td></td><td></td></tr> -->
+  </table>
+
+  <p>Last Updated: 16-Jul-2017</p>
+</div>
+</body>
+</html>

Modified: vendor/libc++/dist/www/index.html
==============================================================================
--- vendor/libc++/dist/www/index.html	Wed Jul 19 07:02:46 2017	(r321189)
+++ vendor/libc++/dist/www/index.html	Wed Jul 19 07:02:49 2017	(r321190)
@@ -138,6 +138,8 @@
       C++14 can be found <a href="cxx1y_status.html">here</a>.</p>
    <p>A list of features and changes for the next C++ standard, known here as
       "C++1z" (probably to be C++17) can be found <a href="cxx1z_status.html">here</a>.</p>
+   <p>A list of features and changes for the C++ standard beyond C++17, known here as
+      "C++2a" (probably to be C++20) can be found <a href="cxx2a_status.html">here</a>.</p>
    <p>Implementation of the post-c++14 Technical Specifications is in progress. A list of features and
       the current status of these features can be found <a href="ts1z_status.html">here</a>.</p>
 

Modified: vendor/libc++/dist/www/upcoming_meeting.html
==============================================================================
--- vendor/libc++/dist/www/upcoming_meeting.html	Wed Jul 19 07:02:46 2017	(r321189)
+++ vendor/libc++/dist/www/upcoming_meeting.html	Wed Jul 19 07:02:49 2017	(r321190)
@@ -73,7 +73,11 @@
 	<tr><td><a href="http://wg21.link/LWG2974">2974</a></td><td>Diagnose out of bounds tuple_element/variant_alternative</td><td>Toronto</td><td></td></tr>
 
 	<tr><td></td><td><center><b>Priority 1 Bugs</b></center></td><td></td><td></td></tr>
-	<tr><td><a href="http://wg21.link/LWG2665">2665</a></td><td>remove_filename() post condition is incorrect</td><td>Kona</td><td>We do this already</td></tr>
+	<tr><td><a href="http://wg21.link/LWG2665">2665</a></td><td>remove_filename() post condition is incorrect</td><td>Toronto</td><td>We do this already</td></tr>
+
+	<tr><td></td><td><center><b>Immediate Issues in Toronto</b></center></td><td></td><td></td></tr>
+	<tr><td><a href="http://wg21.link/LWG2901">2901</a></td><td>Variants cannot properly support allocators</td><td>Toronto</td><td>We do this already</td></tr>
+	<tr><td><a href="http://wg21.link/LWG2956">2956</a></td><td><tt>filesystem::canonical()</tt> still defined in terms of <tt>absolute(p, base)</tt></td><td>Toronto</td><td></td></tr>
 
   </table>
 


More information about the svn-src-vendor mailing list