aboutsummaryrefslogtreecommitdiff
path: root/libstdc++-v3
diff options
context:
space:
mode:
authorMartin Liska <mliska@suse.cz>2022-09-29 10:41:04 +0200
committerMartin Liska <mliska@suse.cz>2022-09-29 10:41:04 +0200
commit54f3cfaf3a6f50958c71d79c85206a6c722e1a22 (patch)
tree5f33297a30acc0df71baa0566cffa701eb97ab4e /libstdc++-v3
parent3c527a35fa428b727807c81f1225a5e0025446c1 (diff)
parenta1cd4d52d6ef90b977fb2d80c1cf17f3efa5b01d (diff)
downloadgcc-54f3cfaf3a6f50958c71d79c85206a6c722e1a22.zip
gcc-54f3cfaf3a6f50958c71d79c85206a6c722e1a22.tar.gz
gcc-54f3cfaf3a6f50958c71d79c85206a6c722e1a22.tar.bz2
Merge branch 'master' into devel/sphinx
Diffstat (limited to 'libstdc++-v3')
-rw-r--r--libstdc++-v3/ChangeLog84
-rw-r--r--libstdc++-v3/doc/html/index.html2
-rw-r--r--libstdc++-v3/doc/html/manual/api.html5
-rw-r--r--libstdc++-v3/doc/html/manual/appendix.html2
-rw-r--r--libstdc++-v3/doc/html/manual/appendix_porting.html2
-rw-r--r--libstdc++-v3/doc/html/manual/bugs.html6
-rw-r--r--libstdc++-v3/doc/html/manual/index.html2
-rw-r--r--libstdc++-v3/doc/html/manual/using_macros.html5
-rw-r--r--libstdc++-v3/doc/xml/manual/evolution.xml13
-rw-r--r--libstdc++-v3/doc/xml/manual/intro.xml9
-rw-r--r--libstdc++-v3/doc/xml/manual/using.xml5
-rw-r--r--libstdc++-v3/include/bits/invoke.h30
-rw-r--r--libstdc++-v3/include/bits/ptr_traits.h20
-rw-r--r--libstdc++-v3/include/bits/std_function.h25
-rw-r--r--libstdc++-v3/include/std/functional32
-rw-r--r--libstdc++-v3/include/std/future4
-rw-r--r--libstdc++-v3/include/std/type_traits54
-rw-r--r--libstdc++-v3/testsuite/20_util/bind/cv_quals.cc25
-rw-r--r--libstdc++-v3/testsuite/20_util/bind/cv_quals_2.cc12
-rw-r--r--libstdc++-v3/testsuite/20_util/bind/dangling_ref.cc9
-rw-r--r--libstdc++-v3/testsuite/20_util/function/cons/70692.cc13
-rw-r--r--libstdc++-v3/testsuite/20_util/function/cons/deduction_c++23.cc23
-rw-r--r--libstdc++-v3/testsuite/20_util/function_objects/invoke/dangling_ref.cc12
-rw-r--r--libstdc++-v3/testsuite/20_util/is_convertible/requirements/access.cc18
-rw-r--r--libstdc++-v3/testsuite/20_util/is_invocable/dangling_ref.cc6
-rw-r--r--libstdc++-v3/testsuite/20_util/pointer_traits/lwg3545.cc17
-rw-r--r--libstdc++-v3/testsuite/30_threads/packaged_task/cons/dangling_ref.cc11
-rw-r--r--libstdc++-v3/testsuite/30_threads/packaged_task/cons/deduction_c++23.cc23
28 files changed, 386 insertions, 83 deletions
diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog
index e6722cf..a1585d8 100644
--- a/libstdc++-v3/ChangeLog
+++ b/libstdc++-v3/ChangeLog
@@ -1,3 +1,87 @@
+2022-09-28 Jonathan Wakely <jwakely@redhat.com>
+
+ * doc/xml/manual/evolution.xml: Document std::bind API
+ changes.
+ * doc/xml/manual/intro.xml: Document LWG 2487 status.
+ * doc/xml/manual/using.xml: Clarify default value of
+ _GLIBCXX_USE_DEPRECATED.
+ * doc/html/*: Regenerate.
+ * include/std/functional (_Bind::operator()(Args&&...) volatile)
+ (_Bind::operator()(Args&&...) const volatile)
+ (_Bind_result::operator()(Args&&...) volatile)
+ (_Bind_result::operator()(Args&&...) const volatile): Replace
+ with deleted overload for C++20 and later.
+ * testsuite/20_util/bind/cv_quals.cc: Check for deprecated
+ warnings in C++17.
+ * testsuite/20_util/bind/cv_quals_2.cc: Likewise, and check for
+ ill-formed in C++20.
+
+2022-09-28 Jonathan Wakely <jwakely@redhat.com>
+
+ PR libstdc++/70692
+ * include/bits/invoke.h [__cplusplus < 201703] (__invoke_r):
+ Remove is_invocable and is_convertible constraints.
+ * include/std/type_traits (__is_invocable_impl::_S_conv): Use
+ non-deduced context for parameter.
+ (__is_invocable_impl::_S_test): Remove _Check_noex template
+ parameter and use deduced noexcept value in its place. Add bool
+ parameter to detect dangling references.
+ (__is_invocable_impl::type): Adjust call to _S_test to avoid
+ deducing unnecessary noexcept property..
+ (__is_invocable_impl::__nothrow_type): Rename to ...
+ (__is_invocable_impl::__nothrow_conv): ... this. Adjust call
+ to _S_test to deduce noexcept property.
+ * testsuite/20_util/bind/dangling_ref.cc: New test.
+ * testsuite/20_util/function/cons/70692.cc: New test.
+ * testsuite/20_util/function_objects/invoke/dangling_ref.cc:
+ New test.
+ * testsuite/20_util/is_invocable/dangling_ref.cc: New test.
+ * testsuite/30_threads/packaged_task/cons/dangling_ref.cc:
+ New test.
+
+2022-09-27 Jonathan Wakely <jwakely@redhat.com>
+
+ PR c++/107049
+ * testsuite/20_util/is_convertible/requirements/access.cc: New
+ test.
+
+2022-09-27 Jonathan Wakely <jwakely@redhat.com>
+
+ PR c++/106651
+ * include/bits/std_function.h (__function_guide_t): New alias
+ template.
+ [__cpp_static_call_operator] (__function_guide_static_helper):
+ New class template.
+ (function): Use __function_guide_t in deduction guide.
+ * include/std/future (packaged_task): Use __function_guide_t in
+ deduction guide.
+ * testsuite/20_util/function/cons/deduction_c++23.cc: New test.
+ * testsuite/30_threads/packaged_task/cons/deduction_c++23.cc:
+ New test.
+
+2022-09-26 Jonathan Wakely <jwakely@redhat.com>
+
+ * include/bits/ptr_traits.h (__ptr_traits_elem) [__cpp_concepts]:
+ Also define the __ptr_traits_elem class template for the
+ concepts case.
+ (pointer_traits<Ptr>): Remove constrained partial
+ specialization.
+ * testsuite/20_util/pointer_traits/lwg3545.cc: Check for
+ ambiguitiy with program-defined partial specialization.
+
+2022-09-26 Jonathan Wakely <jwakely@redhat.com>
+
+ * include/std/type_traits (is_convertible, is_convertible_v):
+ Define using new built-in.
+ (is_nothrow_convertible is_nothrow_convertible_v): Likewise.
+
+2022-09-26 Jonathan Wakely <jwakely@redhat.com>
+
+ PR libstdc++/107037
+ * include/std/bitset (_Base_bitset::_M_do_reset): Use
+ preprocessor conditional around non-C++03 code.
+ * testsuite/20_util/bitset/107037.cc: New test.
+
2022-09-24 Jonathan Wakely <jwakely@redhat.com>
* include/bits/alloc_traits.h (allocator_traits::is_always_equal):
diff --git a/libstdc++-v3/doc/html/index.html b/libstdc++-v3/doc/html/index.html
index 5cc9226..1e0cecb 100644
--- a/libstdc++-v3/doc/html/index.html
+++ b/libstdc++-v3/doc/html/index.html
@@ -142,7 +142,7 @@
Existing tests
</a></span></dt><dt><span class="section"><a href="manual/test.html#test.exception.safety.containers">
C++11 Requirements Test Sequence Descriptions
-</a></span></dt></dl></dd></dl></dd></dl></dd><dt><span class="section"><a href="manual/abi.html">ABI Policy and Guidelines</a></span></dt><dd><dl><dt><span class="section"><a href="manual/abi.html#abi.cxx_interface">The C++ Interface</a></span></dt><dt><span class="section"><a href="manual/abi.html#abi.versioning">Versioning</a></span></dt><dd><dl><dt><span class="section"><a href="manual/abi.html#abi.versioning.goals">Goals</a></span></dt><dt><span class="section"><a href="manual/abi.html#abi.versioning.history">History</a></span></dt><dt><span class="section"><a href="manual/abi.html#abi.versioning.prereq">Prerequisites</a></span></dt><dt><span class="section"><a href="manual/abi.html#abi.versioning.config">Configuring</a></span></dt><dt><span class="section"><a href="manual/abi.html#abi.versioning.active">Checking Active</a></span></dt></dl></dd><dt><span class="section"><a href="manual/abi.html#abi.changes_allowed">Allowed Changes</a></span></dt><dt><span class="section"><a href="manual/abi.html#abi.changes_no">Prohibited Changes</a></span></dt><dt><span class="section"><a href="manual/abi.html#abi.impl">Implementation</a></span></dt><dt><span class="section"><a href="manual/abi.html#abi.testing">Testing</a></span></dt><dd><dl><dt><span class="section"><a href="manual/abi.html#abi.testing.single">Single ABI Testing</a></span></dt><dt><span class="section"><a href="manual/abi.html#abi.testing.multi">Multiple ABI Testing</a></span></dt></dl></dd><dt><span class="section"><a href="manual/abi.html#abi.issues">Outstanding Issues</a></span></dt></dl></dd><dt><span class="section"><a href="manual/api.html">API Evolution and Deprecation History</a></span></dt><dd><dl><dt><span class="section"><a href="manual/api.html#api.rel_300"><code class="constant">3.0</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_310"><code class="constant">3.1</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_320"><code class="constant">3.2</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_330"><code class="constant">3.3</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_340"><code class="constant">3.4</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_400"><code class="constant">4.0</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_410"><code class="constant">4.1</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_420"><code class="constant">4.2</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_430"><code class="constant">4.3</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_440"><code class="constant">4.4</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_450"><code class="constant">4.5</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_460"><code class="constant">4.6</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_470"><code class="constant">4.7</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_480"><code class="constant">4.8</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_490"><code class="constant">4.9</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_51"><code class="constant">5</code></a></span></dt><dd><dl><dt><span class="section"><a href="manual/api.html#api.rel_53"><code class="constant">5.3</code></a></span></dt></dl></dd><dt><span class="section"><a href="manual/api.html#api.rel_61"><code class="constant">6</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_71"><code class="constant">7</code></a></span></dt><dd><dl><dt><span class="section"><a href="manual/api.html#api.rel_72"><code class="constant">7.2</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_73"><code class="constant">7.3</code></a></span></dt></dl></dd><dt><span class="section"><a href="manual/api.html#api.rel_81"><code class="constant">8</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_91"><code class="constant">9</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_101"><code class="constant">10</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_111"><code class="constant">11</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_121"><code class="constant">12</code></a></span></dt></dl></dd><dt><span class="section"><a href="manual/backwards.html">Backwards Compatibility</a></span></dt><dd><dl><dt><span class="section"><a href="manual/backwards.html#backwards.first">First</a></span></dt><dt><span class="section"><a href="manual/backwards.html#backwards.second">Second</a></span></dt><dt><span class="section"><a href="manual/backwards.html#backwards.third">Third</a></span></dt><dd><dl><dt><span class="section"><a href="manual/backwards.html#backwards.third.headers">Pre-ISO headers removed</a></span></dt><dt><span class="section"><a href="manual/backwards.html#backwards.third.hash">Extension headers hash_map, hash_set moved to ext or backwards</a></span></dt><dt><span class="section"><a href="manual/backwards.html#backwards.third.nocreate_noreplace">No <code class="code">ios::nocreate/ios::noreplace</code>.
+</a></span></dt></dl></dd></dl></dd></dl></dd><dt><span class="section"><a href="manual/abi.html">ABI Policy and Guidelines</a></span></dt><dd><dl><dt><span class="section"><a href="manual/abi.html#abi.cxx_interface">The C++ Interface</a></span></dt><dt><span class="section"><a href="manual/abi.html#abi.versioning">Versioning</a></span></dt><dd><dl><dt><span class="section"><a href="manual/abi.html#abi.versioning.goals">Goals</a></span></dt><dt><span class="section"><a href="manual/abi.html#abi.versioning.history">History</a></span></dt><dt><span class="section"><a href="manual/abi.html#abi.versioning.prereq">Prerequisites</a></span></dt><dt><span class="section"><a href="manual/abi.html#abi.versioning.config">Configuring</a></span></dt><dt><span class="section"><a href="manual/abi.html#abi.versioning.active">Checking Active</a></span></dt></dl></dd><dt><span class="section"><a href="manual/abi.html#abi.changes_allowed">Allowed Changes</a></span></dt><dt><span class="section"><a href="manual/abi.html#abi.changes_no">Prohibited Changes</a></span></dt><dt><span class="section"><a href="manual/abi.html#abi.impl">Implementation</a></span></dt><dt><span class="section"><a href="manual/abi.html#abi.testing">Testing</a></span></dt><dd><dl><dt><span class="section"><a href="manual/abi.html#abi.testing.single">Single ABI Testing</a></span></dt><dt><span class="section"><a href="manual/abi.html#abi.testing.multi">Multiple ABI Testing</a></span></dt></dl></dd><dt><span class="section"><a href="manual/abi.html#abi.issues">Outstanding Issues</a></span></dt></dl></dd><dt><span class="section"><a href="manual/api.html">API Evolution and Deprecation History</a></span></dt><dd><dl><dt><span class="section"><a href="manual/api.html#api.rel_300"><code class="constant">3.0</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_310"><code class="constant">3.1</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_320"><code class="constant">3.2</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_330"><code class="constant">3.3</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_340"><code class="constant">3.4</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_400"><code class="constant">4.0</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_410"><code class="constant">4.1</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_420"><code class="constant">4.2</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_430"><code class="constant">4.3</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_440"><code class="constant">4.4</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_450"><code class="constant">4.5</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_460"><code class="constant">4.6</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_470"><code class="constant">4.7</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_480"><code class="constant">4.8</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_490"><code class="constant">4.9</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_51"><code class="constant">5</code></a></span></dt><dd><dl><dt><span class="section"><a href="manual/api.html#api.rel_53"><code class="constant">5.3</code></a></span></dt></dl></dd><dt><span class="section"><a href="manual/api.html#api.rel_61"><code class="constant">6</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_71"><code class="constant">7</code></a></span></dt><dd><dl><dt><span class="section"><a href="manual/api.html#api.rel_72"><code class="constant">7.2</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_73"><code class="constant">7.3</code></a></span></dt></dl></dd><dt><span class="section"><a href="manual/api.html#api.rel_81"><code class="constant">8</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_91"><code class="constant">9</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_101"><code class="constant">10</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_111"><code class="constant">11</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_121"><code class="constant">12</code></a></span></dt><dt><span class="section"><a href="manual/api.html#api.rel_123"><code class="constant">12.3</code></a></span></dt></dl></dd><dt><span class="section"><a href="manual/backwards.html">Backwards Compatibility</a></span></dt><dd><dl><dt><span class="section"><a href="manual/backwards.html#backwards.first">First</a></span></dt><dt><span class="section"><a href="manual/backwards.html#backwards.second">Second</a></span></dt><dt><span class="section"><a href="manual/backwards.html#backwards.third">Third</a></span></dt><dd><dl><dt><span class="section"><a href="manual/backwards.html#backwards.third.headers">Pre-ISO headers removed</a></span></dt><dt><span class="section"><a href="manual/backwards.html#backwards.third.hash">Extension headers hash_map, hash_set moved to ext or backwards</a></span></dt><dt><span class="section"><a href="manual/backwards.html#backwards.third.nocreate_noreplace">No <code class="code">ios::nocreate/ios::noreplace</code>.
</a></span></dt><dt><span class="section"><a href="manual/backwards.html#backwards.third.streamattach">
No <code class="code">stream::attach(int fd)</code>
</a></span></dt><dt><span class="section"><a href="manual/backwards.html#backwards.third.support_cxx98">
diff --git a/libstdc++-v3/doc/html/manual/api.html b/libstdc++-v3/doc/html/manual/api.html
index bbda6f5..604380e 100644
--- a/libstdc++-v3/doc/html/manual/api.html
+++ b/libstdc++-v3/doc/html/manual/api.html
@@ -316,6 +316,8 @@ now defaults to zero.
<code class="classname">has_trivial_default_constructor</code>,
<code class="classname">has_trivial_copy_constructor</code> and
<code class="classname">has_trivial_copy_assign</code> removed.
+</p><p>
+Calling a <code class="code">std::bind</code> result as volatile was deprecated for C++17.
</p><p> Profile Mode was deprecated. </p><div class="section"><div class="titlepage"><div><div><h4 class="title"><a id="api.rel_72"></a><code class="constant">7.2</code></h4></div></div></div><p>
Library Fundamentals TS header
<code class="filename">&lt;experimental/source_location&gt;</code>
@@ -468,4 +470,7 @@ they both derive from <code class="classname">std::__new_allocator</code> instea
<code class="code">noexcept(false)</code> to allow thread cancellation exceptions to
be thrown from <code class="function">pthread_cond_wait</code> without aborting
the process.
+</p></div><div class="section"><div class="titlepage"><div><div><h3 class="title"><a id="api.rel_123"></a><code class="constant">12.3</code></h3></div></div></div><p>
+Calling a <code class="code">std::bind</code> result as volatile is ill-formed for C++20
+and later.
</p></div></div><div class="navfooter"><hr /><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="abi.html">Prev</a> </td><td width="20%" align="center"><a accesskey="u" href="appendix_porting.html">Up</a></td><td width="40%" align="right"> <a accesskey="n" href="backwards.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">ABI Policy and Guidelines </td><td width="20%" align="center"><a accesskey="h" href="../index.html">Home</a></td><td width="40%" align="right" valign="top"> Backwards Compatibility</td></tr></table></div></body></html> \ No newline at end of file
diff --git a/libstdc++-v3/doc/html/manual/appendix.html b/libstdc++-v3/doc/html/manual/appendix.html
index bd462e9..c563372 100644
--- a/libstdc++-v3/doc/html/manual/appendix.html
+++ b/libstdc++-v3/doc/html/manual/appendix.html
@@ -16,7 +16,7 @@
Existing tests
</a></span></dt><dt><span class="section"><a href="test.html#test.exception.safety.containers">
C++11 Requirements Test Sequence Descriptions
-</a></span></dt></dl></dd></dl></dd></dl></dd><dt><span class="section"><a href="abi.html">ABI Policy and Guidelines</a></span></dt><dd><dl><dt><span class="section"><a href="abi.html#abi.cxx_interface">The C++ Interface</a></span></dt><dt><span class="section"><a href="abi.html#abi.versioning">Versioning</a></span></dt><dd><dl><dt><span class="section"><a href="abi.html#abi.versioning.goals">Goals</a></span></dt><dt><span class="section"><a href="abi.html#abi.versioning.history">History</a></span></dt><dt><span class="section"><a href="abi.html#abi.versioning.prereq">Prerequisites</a></span></dt><dt><span class="section"><a href="abi.html#abi.versioning.config">Configuring</a></span></dt><dt><span class="section"><a href="abi.html#abi.versioning.active">Checking Active</a></span></dt></dl></dd><dt><span class="section"><a href="abi.html#abi.changes_allowed">Allowed Changes</a></span></dt><dt><span class="section"><a href="abi.html#abi.changes_no">Prohibited Changes</a></span></dt><dt><span class="section"><a href="abi.html#abi.impl">Implementation</a></span></dt><dt><span class="section"><a href="abi.html#abi.testing">Testing</a></span></dt><dd><dl><dt><span class="section"><a href="abi.html#abi.testing.single">Single ABI Testing</a></span></dt><dt><span class="section"><a href="abi.html#abi.testing.multi">Multiple ABI Testing</a></span></dt></dl></dd><dt><span class="section"><a href="abi.html#abi.issues">Outstanding Issues</a></span></dt></dl></dd><dt><span class="section"><a href="api.html">API Evolution and Deprecation History</a></span></dt><dd><dl><dt><span class="section"><a href="api.html#api.rel_300"><code class="constant">3.0</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_310"><code class="constant">3.1</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_320"><code class="constant">3.2</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_330"><code class="constant">3.3</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_340"><code class="constant">3.4</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_400"><code class="constant">4.0</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_410"><code class="constant">4.1</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_420"><code class="constant">4.2</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_430"><code class="constant">4.3</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_440"><code class="constant">4.4</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_450"><code class="constant">4.5</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_460"><code class="constant">4.6</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_470"><code class="constant">4.7</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_480"><code class="constant">4.8</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_490"><code class="constant">4.9</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_51"><code class="constant">5</code></a></span></dt><dd><dl><dt><span class="section"><a href="api.html#api.rel_53"><code class="constant">5.3</code></a></span></dt></dl></dd><dt><span class="section"><a href="api.html#api.rel_61"><code class="constant">6</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_71"><code class="constant">7</code></a></span></dt><dd><dl><dt><span class="section"><a href="api.html#api.rel_72"><code class="constant">7.2</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_73"><code class="constant">7.3</code></a></span></dt></dl></dd><dt><span class="section"><a href="api.html#api.rel_81"><code class="constant">8</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_91"><code class="constant">9</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_101"><code class="constant">10</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_111"><code class="constant">11</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_121"><code class="constant">12</code></a></span></dt></dl></dd><dt><span class="section"><a href="backwards.html">Backwards Compatibility</a></span></dt><dd><dl><dt><span class="section"><a href="backwards.html#backwards.first">First</a></span></dt><dt><span class="section"><a href="backwards.html#backwards.second">Second</a></span></dt><dt><span class="section"><a href="backwards.html#backwards.third">Third</a></span></dt><dd><dl><dt><span class="section"><a href="backwards.html#backwards.third.headers">Pre-ISO headers removed</a></span></dt><dt><span class="section"><a href="backwards.html#backwards.third.hash">Extension headers hash_map, hash_set moved to ext or backwards</a></span></dt><dt><span class="section"><a href="backwards.html#backwards.third.nocreate_noreplace">No <code class="code">ios::nocreate/ios::noreplace</code>.
+</a></span></dt></dl></dd></dl></dd></dl></dd><dt><span class="section"><a href="abi.html">ABI Policy and Guidelines</a></span></dt><dd><dl><dt><span class="section"><a href="abi.html#abi.cxx_interface">The C++ Interface</a></span></dt><dt><span class="section"><a href="abi.html#abi.versioning">Versioning</a></span></dt><dd><dl><dt><span class="section"><a href="abi.html#abi.versioning.goals">Goals</a></span></dt><dt><span class="section"><a href="abi.html#abi.versioning.history">History</a></span></dt><dt><span class="section"><a href="abi.html#abi.versioning.prereq">Prerequisites</a></span></dt><dt><span class="section"><a href="abi.html#abi.versioning.config">Configuring</a></span></dt><dt><span class="section"><a href="abi.html#abi.versioning.active">Checking Active</a></span></dt></dl></dd><dt><span class="section"><a href="abi.html#abi.changes_allowed">Allowed Changes</a></span></dt><dt><span class="section"><a href="abi.html#abi.changes_no">Prohibited Changes</a></span></dt><dt><span class="section"><a href="abi.html#abi.impl">Implementation</a></span></dt><dt><span class="section"><a href="abi.html#abi.testing">Testing</a></span></dt><dd><dl><dt><span class="section"><a href="abi.html#abi.testing.single">Single ABI Testing</a></span></dt><dt><span class="section"><a href="abi.html#abi.testing.multi">Multiple ABI Testing</a></span></dt></dl></dd><dt><span class="section"><a href="abi.html#abi.issues">Outstanding Issues</a></span></dt></dl></dd><dt><span class="section"><a href="api.html">API Evolution and Deprecation History</a></span></dt><dd><dl><dt><span class="section"><a href="api.html#api.rel_300"><code class="constant">3.0</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_310"><code class="constant">3.1</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_320"><code class="constant">3.2</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_330"><code class="constant">3.3</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_340"><code class="constant">3.4</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_400"><code class="constant">4.0</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_410"><code class="constant">4.1</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_420"><code class="constant">4.2</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_430"><code class="constant">4.3</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_440"><code class="constant">4.4</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_450"><code class="constant">4.5</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_460"><code class="constant">4.6</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_470"><code class="constant">4.7</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_480"><code class="constant">4.8</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_490"><code class="constant">4.9</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_51"><code class="constant">5</code></a></span></dt><dd><dl><dt><span class="section"><a href="api.html#api.rel_53"><code class="constant">5.3</code></a></span></dt></dl></dd><dt><span class="section"><a href="api.html#api.rel_61"><code class="constant">6</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_71"><code class="constant">7</code></a></span></dt><dd><dl><dt><span class="section"><a href="api.html#api.rel_72"><code class="constant">7.2</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_73"><code class="constant">7.3</code></a></span></dt></dl></dd><dt><span class="section"><a href="api.html#api.rel_81"><code class="constant">8</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_91"><code class="constant">9</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_101"><code class="constant">10</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_111"><code class="constant">11</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_121"><code class="constant">12</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_123"><code class="constant">12.3</code></a></span></dt></dl></dd><dt><span class="section"><a href="backwards.html">Backwards Compatibility</a></span></dt><dd><dl><dt><span class="section"><a href="backwards.html#backwards.first">First</a></span></dt><dt><span class="section"><a href="backwards.html#backwards.second">Second</a></span></dt><dt><span class="section"><a href="backwards.html#backwards.third">Third</a></span></dt><dd><dl><dt><span class="section"><a href="backwards.html#backwards.third.headers">Pre-ISO headers removed</a></span></dt><dt><span class="section"><a href="backwards.html#backwards.third.hash">Extension headers hash_map, hash_set moved to ext or backwards</a></span></dt><dt><span class="section"><a href="backwards.html#backwards.third.nocreate_noreplace">No <code class="code">ios::nocreate/ios::noreplace</code>.
</a></span></dt><dt><span class="section"><a href="backwards.html#backwards.third.streamattach">
No <code class="code">stream::attach(int fd)</code>
</a></span></dt><dt><span class="section"><a href="backwards.html#backwards.third.support_cxx98">
diff --git a/libstdc++-v3/doc/html/manual/appendix_porting.html b/libstdc++-v3/doc/html/manual/appendix_porting.html
index 3d7fb56..55d3f23 100644
--- a/libstdc++-v3/doc/html/manual/appendix_porting.html
+++ b/libstdc++-v3/doc/html/manual/appendix_porting.html
@@ -14,7 +14,7 @@
Existing tests
</a></span></dt><dt><span class="section"><a href="test.html#test.exception.safety.containers">
C++11 Requirements Test Sequence Descriptions
-</a></span></dt></dl></dd></dl></dd></dl></dd><dt><span class="section"><a href="abi.html">ABI Policy and Guidelines</a></span></dt><dd><dl><dt><span class="section"><a href="abi.html#abi.cxx_interface">The C++ Interface</a></span></dt><dt><span class="section"><a href="abi.html#abi.versioning">Versioning</a></span></dt><dd><dl><dt><span class="section"><a href="abi.html#abi.versioning.goals">Goals</a></span></dt><dt><span class="section"><a href="abi.html#abi.versioning.history">History</a></span></dt><dt><span class="section"><a href="abi.html#abi.versioning.prereq">Prerequisites</a></span></dt><dt><span class="section"><a href="abi.html#abi.versioning.config">Configuring</a></span></dt><dt><span class="section"><a href="abi.html#abi.versioning.active">Checking Active</a></span></dt></dl></dd><dt><span class="section"><a href="abi.html#abi.changes_allowed">Allowed Changes</a></span></dt><dt><span class="section"><a href="abi.html#abi.changes_no">Prohibited Changes</a></span></dt><dt><span class="section"><a href="abi.html#abi.impl">Implementation</a></span></dt><dt><span class="section"><a href="abi.html#abi.testing">Testing</a></span></dt><dd><dl><dt><span class="section"><a href="abi.html#abi.testing.single">Single ABI Testing</a></span></dt><dt><span class="section"><a href="abi.html#abi.testing.multi">Multiple ABI Testing</a></span></dt></dl></dd><dt><span class="section"><a href="abi.html#abi.issues">Outstanding Issues</a></span></dt></dl></dd><dt><span class="section"><a href="api.html">API Evolution and Deprecation History</a></span></dt><dd><dl><dt><span class="section"><a href="api.html#api.rel_300"><code class="constant">3.0</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_310"><code class="constant">3.1</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_320"><code class="constant">3.2</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_330"><code class="constant">3.3</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_340"><code class="constant">3.4</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_400"><code class="constant">4.0</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_410"><code class="constant">4.1</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_420"><code class="constant">4.2</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_430"><code class="constant">4.3</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_440"><code class="constant">4.4</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_450"><code class="constant">4.5</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_460"><code class="constant">4.6</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_470"><code class="constant">4.7</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_480"><code class="constant">4.8</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_490"><code class="constant">4.9</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_51"><code class="constant">5</code></a></span></dt><dd><dl><dt><span class="section"><a href="api.html#api.rel_53"><code class="constant">5.3</code></a></span></dt></dl></dd><dt><span class="section"><a href="api.html#api.rel_61"><code class="constant">6</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_71"><code class="constant">7</code></a></span></dt><dd><dl><dt><span class="section"><a href="api.html#api.rel_72"><code class="constant">7.2</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_73"><code class="constant">7.3</code></a></span></dt></dl></dd><dt><span class="section"><a href="api.html#api.rel_81"><code class="constant">8</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_91"><code class="constant">9</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_101"><code class="constant">10</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_111"><code class="constant">11</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_121"><code class="constant">12</code></a></span></dt></dl></dd><dt><span class="section"><a href="backwards.html">Backwards Compatibility</a></span></dt><dd><dl><dt><span class="section"><a href="backwards.html#backwards.first">First</a></span></dt><dt><span class="section"><a href="backwards.html#backwards.second">Second</a></span></dt><dt><span class="section"><a href="backwards.html#backwards.third">Third</a></span></dt><dd><dl><dt><span class="section"><a href="backwards.html#backwards.third.headers">Pre-ISO headers removed</a></span></dt><dt><span class="section"><a href="backwards.html#backwards.third.hash">Extension headers hash_map, hash_set moved to ext or backwards</a></span></dt><dt><span class="section"><a href="backwards.html#backwards.third.nocreate_noreplace">No <code class="code">ios::nocreate/ios::noreplace</code>.
+</a></span></dt></dl></dd></dl></dd></dl></dd><dt><span class="section"><a href="abi.html">ABI Policy and Guidelines</a></span></dt><dd><dl><dt><span class="section"><a href="abi.html#abi.cxx_interface">The C++ Interface</a></span></dt><dt><span class="section"><a href="abi.html#abi.versioning">Versioning</a></span></dt><dd><dl><dt><span class="section"><a href="abi.html#abi.versioning.goals">Goals</a></span></dt><dt><span class="section"><a href="abi.html#abi.versioning.history">History</a></span></dt><dt><span class="section"><a href="abi.html#abi.versioning.prereq">Prerequisites</a></span></dt><dt><span class="section"><a href="abi.html#abi.versioning.config">Configuring</a></span></dt><dt><span class="section"><a href="abi.html#abi.versioning.active">Checking Active</a></span></dt></dl></dd><dt><span class="section"><a href="abi.html#abi.changes_allowed">Allowed Changes</a></span></dt><dt><span class="section"><a href="abi.html#abi.changes_no">Prohibited Changes</a></span></dt><dt><span class="section"><a href="abi.html#abi.impl">Implementation</a></span></dt><dt><span class="section"><a href="abi.html#abi.testing">Testing</a></span></dt><dd><dl><dt><span class="section"><a href="abi.html#abi.testing.single">Single ABI Testing</a></span></dt><dt><span class="section"><a href="abi.html#abi.testing.multi">Multiple ABI Testing</a></span></dt></dl></dd><dt><span class="section"><a href="abi.html#abi.issues">Outstanding Issues</a></span></dt></dl></dd><dt><span class="section"><a href="api.html">API Evolution and Deprecation History</a></span></dt><dd><dl><dt><span class="section"><a href="api.html#api.rel_300"><code class="constant">3.0</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_310"><code class="constant">3.1</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_320"><code class="constant">3.2</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_330"><code class="constant">3.3</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_340"><code class="constant">3.4</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_400"><code class="constant">4.0</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_410"><code class="constant">4.1</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_420"><code class="constant">4.2</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_430"><code class="constant">4.3</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_440"><code class="constant">4.4</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_450"><code class="constant">4.5</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_460"><code class="constant">4.6</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_470"><code class="constant">4.7</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_480"><code class="constant">4.8</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_490"><code class="constant">4.9</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_51"><code class="constant">5</code></a></span></dt><dd><dl><dt><span class="section"><a href="api.html#api.rel_53"><code class="constant">5.3</code></a></span></dt></dl></dd><dt><span class="section"><a href="api.html#api.rel_61"><code class="constant">6</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_71"><code class="constant">7</code></a></span></dt><dd><dl><dt><span class="section"><a href="api.html#api.rel_72"><code class="constant">7.2</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_73"><code class="constant">7.3</code></a></span></dt></dl></dd><dt><span class="section"><a href="api.html#api.rel_81"><code class="constant">8</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_91"><code class="constant">9</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_101"><code class="constant">10</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_111"><code class="constant">11</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_121"><code class="constant">12</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_123"><code class="constant">12.3</code></a></span></dt></dl></dd><dt><span class="section"><a href="backwards.html">Backwards Compatibility</a></span></dt><dd><dl><dt><span class="section"><a href="backwards.html#backwards.first">First</a></span></dt><dt><span class="section"><a href="backwards.html#backwards.second">Second</a></span></dt><dt><span class="section"><a href="backwards.html#backwards.third">Third</a></span></dt><dd><dl><dt><span class="section"><a href="backwards.html#backwards.third.headers">Pre-ISO headers removed</a></span></dt><dt><span class="section"><a href="backwards.html#backwards.third.hash">Extension headers hash_map, hash_set moved to ext or backwards</a></span></dt><dt><span class="section"><a href="backwards.html#backwards.third.nocreate_noreplace">No <code class="code">ios::nocreate/ios::noreplace</code>.
</a></span></dt><dt><span class="section"><a href="backwards.html#backwards.third.streamattach">
No <code class="code">stream::attach(int fd)</code>
</a></span></dt><dt><span class="section"><a href="backwards.html#backwards.third.support_cxx98">
diff --git a/libstdc++-v3/doc/html/manual/bugs.html b/libstdc++-v3/doc/html/manual/bugs.html
index 384fe8d..8e0bc1f 100644
--- a/libstdc++-v3/doc/html/manual/bugs.html
+++ b/libstdc++-v3/doc/html/manual/bugs.html
@@ -524,6 +524,12 @@
</em></span>
</span></dt><dd><p>Avoid using <code class="code">dynamic_cast</code> when it would be
ill-formed.
+ </p></dd><dt><a id="manual.bugs.dr2487"></a><span class="term"><a class="link" href="http://www.open-std.org/jtc1/sc22/wg21/docs/lwg-defects.html#2487" target="_top">2487</a>:
+ <span class="emphasis"><em><code class="code">bind()</code> should be <code class="code">const</code>-overloaded
+ not cv-overloaded
+ </em></span>
+ </span></dt><dd><p>Deprecate volatile-qualified <code class="code">operator()</code>
+ for C++17, make it ill-formed for C++20.
</p></dd><dt><a id="manual.bugs.dr2499"></a><span class="term"><a class="link" href="http://www.open-std.org/jtc1/sc22/wg21/docs/lwg-defects.html#2499" target="_top">2499</a>:
<span class="emphasis"><em><code class="code">operator&gt;&gt;(basic_istream&amp;, CharT*)</code> makes it hard to avoid buffer overflows
</em></span>
diff --git a/libstdc++-v3/doc/html/manual/index.html b/libstdc++-v3/doc/html/manual/index.html
index 7122dde..2949509 100644
--- a/libstdc++-v3/doc/html/manual/index.html
+++ b/libstdc++-v3/doc/html/manual/index.html
@@ -123,7 +123,7 @@
Existing tests
</a></span></dt><dt><span class="section"><a href="test.html#test.exception.safety.containers">
C++11 Requirements Test Sequence Descriptions
-</a></span></dt></dl></dd></dl></dd></dl></dd><dt><span class="section"><a href="abi.html">ABI Policy and Guidelines</a></span></dt><dd><dl><dt><span class="section"><a href="abi.html#abi.cxx_interface">The C++ Interface</a></span></dt><dt><span class="section"><a href="abi.html#abi.versioning">Versioning</a></span></dt><dd><dl><dt><span class="section"><a href="abi.html#abi.versioning.goals">Goals</a></span></dt><dt><span class="section"><a href="abi.html#abi.versioning.history">History</a></span></dt><dt><span class="section"><a href="abi.html#abi.versioning.prereq">Prerequisites</a></span></dt><dt><span class="section"><a href="abi.html#abi.versioning.config">Configuring</a></span></dt><dt><span class="section"><a href="abi.html#abi.versioning.active">Checking Active</a></span></dt></dl></dd><dt><span class="section"><a href="abi.html#abi.changes_allowed">Allowed Changes</a></span></dt><dt><span class="section"><a href="abi.html#abi.changes_no">Prohibited Changes</a></span></dt><dt><span class="section"><a href="abi.html#abi.impl">Implementation</a></span></dt><dt><span class="section"><a href="abi.html#abi.testing">Testing</a></span></dt><dd><dl><dt><span class="section"><a href="abi.html#abi.testing.single">Single ABI Testing</a></span></dt><dt><span class="section"><a href="abi.html#abi.testing.multi">Multiple ABI Testing</a></span></dt></dl></dd><dt><span class="section"><a href="abi.html#abi.issues">Outstanding Issues</a></span></dt></dl></dd><dt><span class="section"><a href="api.html">API Evolution and Deprecation History</a></span></dt><dd><dl><dt><span class="section"><a href="api.html#api.rel_300"><code class="constant">3.0</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_310"><code class="constant">3.1</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_320"><code class="constant">3.2</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_330"><code class="constant">3.3</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_340"><code class="constant">3.4</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_400"><code class="constant">4.0</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_410"><code class="constant">4.1</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_420"><code class="constant">4.2</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_430"><code class="constant">4.3</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_440"><code class="constant">4.4</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_450"><code class="constant">4.5</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_460"><code class="constant">4.6</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_470"><code class="constant">4.7</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_480"><code class="constant">4.8</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_490"><code class="constant">4.9</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_51"><code class="constant">5</code></a></span></dt><dd><dl><dt><span class="section"><a href="api.html#api.rel_53"><code class="constant">5.3</code></a></span></dt></dl></dd><dt><span class="section"><a href="api.html#api.rel_61"><code class="constant">6</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_71"><code class="constant">7</code></a></span></dt><dd><dl><dt><span class="section"><a href="api.html#api.rel_72"><code class="constant">7.2</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_73"><code class="constant">7.3</code></a></span></dt></dl></dd><dt><span class="section"><a href="api.html#api.rel_81"><code class="constant">8</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_91"><code class="constant">9</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_101"><code class="constant">10</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_111"><code class="constant">11</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_121"><code class="constant">12</code></a></span></dt></dl></dd><dt><span class="section"><a href="backwards.html">Backwards Compatibility</a></span></dt><dd><dl><dt><span class="section"><a href="backwards.html#backwards.first">First</a></span></dt><dt><span class="section"><a href="backwards.html#backwards.second">Second</a></span></dt><dt><span class="section"><a href="backwards.html#backwards.third">Third</a></span></dt><dd><dl><dt><span class="section"><a href="backwards.html#backwards.third.headers">Pre-ISO headers removed</a></span></dt><dt><span class="section"><a href="backwards.html#backwards.third.hash">Extension headers hash_map, hash_set moved to ext or backwards</a></span></dt><dt><span class="section"><a href="backwards.html#backwards.third.nocreate_noreplace">No <code class="code">ios::nocreate/ios::noreplace</code>.
+</a></span></dt></dl></dd></dl></dd></dl></dd><dt><span class="section"><a href="abi.html">ABI Policy and Guidelines</a></span></dt><dd><dl><dt><span class="section"><a href="abi.html#abi.cxx_interface">The C++ Interface</a></span></dt><dt><span class="section"><a href="abi.html#abi.versioning">Versioning</a></span></dt><dd><dl><dt><span class="section"><a href="abi.html#abi.versioning.goals">Goals</a></span></dt><dt><span class="section"><a href="abi.html#abi.versioning.history">History</a></span></dt><dt><span class="section"><a href="abi.html#abi.versioning.prereq">Prerequisites</a></span></dt><dt><span class="section"><a href="abi.html#abi.versioning.config">Configuring</a></span></dt><dt><span class="section"><a href="abi.html#abi.versioning.active">Checking Active</a></span></dt></dl></dd><dt><span class="section"><a href="abi.html#abi.changes_allowed">Allowed Changes</a></span></dt><dt><span class="section"><a href="abi.html#abi.changes_no">Prohibited Changes</a></span></dt><dt><span class="section"><a href="abi.html#abi.impl">Implementation</a></span></dt><dt><span class="section"><a href="abi.html#abi.testing">Testing</a></span></dt><dd><dl><dt><span class="section"><a href="abi.html#abi.testing.single">Single ABI Testing</a></span></dt><dt><span class="section"><a href="abi.html#abi.testing.multi">Multiple ABI Testing</a></span></dt></dl></dd><dt><span class="section"><a href="abi.html#abi.issues">Outstanding Issues</a></span></dt></dl></dd><dt><span class="section"><a href="api.html">API Evolution and Deprecation History</a></span></dt><dd><dl><dt><span class="section"><a href="api.html#api.rel_300"><code class="constant">3.0</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_310"><code class="constant">3.1</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_320"><code class="constant">3.2</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_330"><code class="constant">3.3</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_340"><code class="constant">3.4</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_400"><code class="constant">4.0</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_410"><code class="constant">4.1</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_420"><code class="constant">4.2</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_430"><code class="constant">4.3</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_440"><code class="constant">4.4</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_450"><code class="constant">4.5</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_460"><code class="constant">4.6</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_470"><code class="constant">4.7</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_480"><code class="constant">4.8</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_490"><code class="constant">4.9</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_51"><code class="constant">5</code></a></span></dt><dd><dl><dt><span class="section"><a href="api.html#api.rel_53"><code class="constant">5.3</code></a></span></dt></dl></dd><dt><span class="section"><a href="api.html#api.rel_61"><code class="constant">6</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_71"><code class="constant">7</code></a></span></dt><dd><dl><dt><span class="section"><a href="api.html#api.rel_72"><code class="constant">7.2</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_73"><code class="constant">7.3</code></a></span></dt></dl></dd><dt><span class="section"><a href="api.html#api.rel_81"><code class="constant">8</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_91"><code class="constant">9</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_101"><code class="constant">10</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_111"><code class="constant">11</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_121"><code class="constant">12</code></a></span></dt><dt><span class="section"><a href="api.html#api.rel_123"><code class="constant">12.3</code></a></span></dt></dl></dd><dt><span class="section"><a href="backwards.html">Backwards Compatibility</a></span></dt><dd><dl><dt><span class="section"><a href="backwards.html#backwards.first">First</a></span></dt><dt><span class="section"><a href="backwards.html#backwards.second">Second</a></span></dt><dt><span class="section"><a href="backwards.html#backwards.third">Third</a></span></dt><dd><dl><dt><span class="section"><a href="backwards.html#backwards.third.headers">Pre-ISO headers removed</a></span></dt><dt><span class="section"><a href="backwards.html#backwards.third.hash">Extension headers hash_map, hash_set moved to ext or backwards</a></span></dt><dt><span class="section"><a href="backwards.html#backwards.third.nocreate_noreplace">No <code class="code">ios::nocreate/ios::noreplace</code>.
</a></span></dt><dt><span class="section"><a href="backwards.html#backwards.third.streamattach">
No <code class="code">stream::attach(int fd)</code>
</a></span></dt><dt><span class="section"><a href="backwards.html#backwards.third.support_cxx98">
diff --git a/libstdc++-v3/doc/html/manual/using_macros.html b/libstdc++-v3/doc/html/manual/using_macros.html
index 9823046..62c66b7 100644
--- a/libstdc++-v3/doc/html/manual/using_macros.html
+++ b/libstdc++-v3/doc/html/manual/using_macros.html
@@ -43,7 +43,7 @@
<a class="link" href="configure.html" title="Configure">Configure</a>),
with the various --enable/--disable choices being translated to
#define/#undef).
- </p><p> <acronym class="acronym">ABI</acronym> means that changing from the default value may
+ </p><p> <acronym class="acronym">ABI</acronym>-changing means that changing from the default value may
mean changing the <acronym class="acronym">ABI</acronym> of compiled code. In other words,
these choices control code which has already been compiled (i.e., in a
binary such as libstdc++.a/.so). If you explicitly #define or
@@ -53,7 +53,8 @@
consistent linkage requires changing the config headers before
building/installing the library.
</p><div class="variablelist"><dl class="variablelist"><dt><span class="term"><code class="code">_GLIBCXX_USE_DEPRECATED</code></span></dt><dd><p>
- Defined by default. Not configurable. ABI-changing. Turning this off
+ Defined to the value <code class="literal">1</code> by default.
+ Not configurable. ABI-changing. Turning this off
removes older ARM-style iostreams code, and other anachronisms
from the API. This macro is dependent on the version of the
standard being tracked, and as a result may give different results for
diff --git a/libstdc++-v3/doc/xml/manual/evolution.xml b/libstdc++-v3/doc/xml/manual/evolution.xml
index 4923e8c..8293618 100644
--- a/libstdc++-v3/doc/xml/manual/evolution.xml
+++ b/libstdc++-v3/doc/xml/manual/evolution.xml
@@ -817,6 +817,10 @@ now defaults to zero.
<classname>has_trivial_copy_assign</classname> removed.
</para>
+<para>
+Calling a <code>std::bind</code> result as volatile was deprecated for C++17.
+</para>
+
<para> Profile Mode was deprecated. </para>
<section xml:id="api.rel_72"><info><title><constant>7.2</constant></title></info>
@@ -1067,4 +1071,13 @@ the process.
</section>
+
+<section xml:id="api.rel_123"><info><title><constant>12.3</constant></title></info>
+<para>
+Calling a <code>std::bind</code> result as volatile is ill-formed for C++20
+and later.
+</para>
+
+</section>
+
</section>
diff --git a/libstdc++-v3/doc/xml/manual/intro.xml b/libstdc++-v3/doc/xml/manual/intro.xml
index d341c3e..e3a03cf 100644
--- a/libstdc++-v3/doc/xml/manual/intro.xml
+++ b/libstdc++-v3/doc/xml/manual/intro.xml
@@ -1163,6 +1163,15 @@ requirements of the license of GCC.
ill-formed.
</para></listitem></varlistentry>
+ <varlistentry xml:id="manual.bugs.dr2487"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2487">2487</link>:
+ <emphasis><code>bind()</code> should be <code>const</code>-overloaded
+ not cv-overloaded
+ </emphasis>
+ </term>
+ <listitem><para>Deprecate volatile-qualified <code>operator()</code>
+ for C++17, make it ill-formed for C++20.
+ </para></listitem></varlistentry>
+
<varlistentry xml:id="manual.bugs.dr2499"><term><link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="&DR;#2499">2499</link>:
<emphasis><code>operator>>(basic_istream&amp;, CharT*)</code> makes it hard to avoid buffer overflows
</emphasis>
diff --git a/libstdc++-v3/doc/xml/manual/using.xml b/libstdc++-v3/doc/xml/manual/using.xml
index 0acdba6..9c444dd 100644
--- a/libstdc++-v3/doc/xml/manual/using.xml
+++ b/libstdc++-v3/doc/xml/manual/using.xml
@@ -1062,7 +1062,7 @@ g++ -Winvalid-pch -I. -include stdc++.h -H -g -O2 hello.cc -o test.exe
#define/#undef).
</para>
- <para> <acronym>ABI</acronym> means that changing from the default value may
+ <para> <acronym>ABI</acronym>-changing means that changing from the default value may
mean changing the <acronym>ABI</acronym> of compiled code. In other words,
these choices control code which has already been compiled (i.e., in a
binary such as libstdc++.a/.so). If you explicitly #define or
@@ -1077,7 +1077,8 @@ g++ -Winvalid-pch -I. -include stdc++.h -H -g -O2 hello.cc -o test.exe
<varlistentry><term><code>_GLIBCXX_USE_DEPRECATED</code></term>
<listitem>
<para>
- Defined by default. Not configurable. ABI-changing. Turning this off
+ Defined to the value <literal>1</literal> by default.
+ Not configurable. ABI-changing. Turning this off
removes older ARM-style iostreams code, and other anachronisms
from the API. This macro is dependent on the version of the
standard being tracked, and as a result may give different results for
diff --git a/libstdc++-v3/include/bits/invoke.h b/libstdc++-v3/include/bits/invoke.h
index cdecca0..8724a76 100644
--- a/libstdc++-v3/include/bits/invoke.h
+++ b/libstdc++-v3/include/bits/invoke.h
@@ -115,29 +115,23 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
std::forward<_Callable>(__fn),
std::forward<_Args>(__args)...);
}
-#else // C++11
- template<typename _Res, typename _Callable, typename... _Args>
- using __can_invoke_as_void = __enable_if_t<
- __and_<is_void<_Res>, __is_invocable<_Callable, _Args...>>::value,
- _Res
- >;
-
- template<typename _Res, typename _Callable, typename... _Args>
- using __can_invoke_as_nonvoid = __enable_if_t<
- __and_<__not_<is_void<_Res>>,
- is_convertible<typename __invoke_result<_Callable, _Args...>::type,
- _Res>
- >::value,
- _Res
- >;
+#else // C++11 or C++14
+ // This is a non-SFINAE-friendly std::invoke_r<R>(fn, args...) for C++11/14.
+ // It's used in std::function, std::bind, and std::packaged_task. Only
+ // std::function is constrained on is_invocable_r, but that is checked on
+ // construction so doesn't need to be checked again when calling __invoke_r.
+ // Consequently, these __invoke_r overloads do not check for invocable
+ // arguments, nor check that the invoke result is convertible to R.
// INVOKE<R>: Invoke a callable object and convert the result to R.
template<typename _Res, typename _Callable, typename... _Args>
- constexpr __can_invoke_as_nonvoid<_Res, _Callable, _Args...>
+ constexpr __enable_if_t<!is_void<_Res>::value, _Res>
__invoke_r(_Callable&& __fn, _Args&&... __args)
{
using __result = __invoke_result<_Callable, _Args...>;
using __type = typename __result::type;
+ static_assert(!__reference_converts_from_temporary(_Res, __type),
+ "INVOKE<R> must not create a dangling reference");
using __tag = typename __result::__invoke_type;
return std::__invoke_impl<__type>(__tag{}, std::forward<_Callable>(__fn),
std::forward<_Args>(__args)...);
@@ -145,7 +139,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
// INVOKE<R> when R is cv void
template<typename _Res, typename _Callable, typename... _Args>
- _GLIBCXX14_CONSTEXPR __can_invoke_as_void<_Res, _Callable, _Args...>
+ _GLIBCXX14_CONSTEXPR __enable_if_t<is_void<_Res>::value, _Res>
__invoke_r(_Callable&& __fn, _Args&&... __args)
{
using __result = __invoke_result<_Callable, _Args...>;
@@ -154,7 +148,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
std::__invoke_impl<__type>(__tag{}, std::forward<_Callable>(__fn),
std::forward<_Args>(__args)...);
}
-#endif // C++11
+#endif // C++11 or C++14
_GLIBCXX_END_NAMESPACE_VERSION
} // namespace std
diff --git a/libstdc++-v3/include/bits/ptr_traits.h b/libstdc++-v3/include/bits/ptr_traits.h
index ae88107..71370ff 100644
--- a/libstdc++-v3/include/bits/ptr_traits.h
+++ b/libstdc++-v3/include/bits/ptr_traits.h
@@ -73,25 +73,24 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
struct __replace_first_arg<_SomeTemplate<_Tp, _Types...>, _Up>
{ using type = _SomeTemplate<_Up, _Types...>; };
-#if __cpp_concepts
- // When concepts are supported detection of _Ptr::element_type is done
- // by a requires-clause, so __ptr_traits_elem_t only needs to do this:
- template<typename _Ptr>
- using __ptr_traits_elem_t = typename __get_first_arg<_Ptr>::type;
-#else
// Detect the element type of a pointer-like type.
template<typename _Ptr, typename = void>
struct __ptr_traits_elem : __get_first_arg<_Ptr>
{ };
// Use _Ptr::element_type if is a valid type.
+#if __cpp_concepts
+ template<typename _Ptr> requires requires { typename _Ptr::element_type; }
+ struct __ptr_traits_elem<_Ptr, void>
+ { using type = typename _Ptr::element_type; };
+#else
template<typename _Ptr>
struct __ptr_traits_elem<_Ptr, __void_t<typename _Ptr::element_type>>
{ using type = typename _Ptr::element_type; };
+#endif
template<typename _Ptr>
using __ptr_traits_elem_t = typename __ptr_traits_elem<_Ptr>::type;
-#endif
/// @endcond
@@ -182,13 +181,6 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
struct pointer_traits : __ptr_traits_impl<_Ptr, __ptr_traits_elem_t<_Ptr>>
{ };
-#if __cpp_concepts
- template<typename _Ptr> requires requires { typename _Ptr::element_type; }
- struct pointer_traits<_Ptr>
- : __ptr_traits_impl<_Ptr, typename _Ptr::element_type>
- { };
-#endif
-
/**
* @brief Partial specialization for built-in pointers.
* @headerfile memory
diff --git a/libstdc++-v3/include/bits/std_function.h b/libstdc++-v3/include/bits/std_function.h
index 96918a0..f5423a3 100644
--- a/libstdc++-v3/include/bits/std_function.h
+++ b/libstdc++-v3/include/bits/std_function.h
@@ -697,12 +697,31 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
>
{ using type = _Res(_Args...); };
+#if __cpp_static_call_operator >= 202207L && __cpp_concepts >= 202002L
+ template<typename _StaticCallOp>
+ struct __function_guide_static_helper
+ { };
+
+ template<typename _Res, bool _Nx, typename... _Args>
+ struct __function_guide_static_helper<_Res (*) (_Args...) noexcept(_Nx)>
+ { using type = _Res(_Args...); };
+
+ template<typename _Fn, typename _Op>
+ using __function_guide_t = typename __conditional_t<
+ requires (_Fn& __f) { (void) __f.operator(); },
+ __function_guide_static_helper<_Op>,
+ __function_guide_helper<_Op>>::type;
+#else
+ template<typename _Fn, typename _Op>
+ using __function_guide_t = typename __function_guide_helper<_Op>::type;
+#endif
+
template<typename _Res, typename... _ArgTypes>
function(_Res(*)(_ArgTypes...)) -> function<_Res(_ArgTypes...)>;
- template<typename _Functor, typename _Signature = typename
- __function_guide_helper<decltype(&_Functor::operator())>::type>
- function(_Functor) -> function<_Signature>;
+ template<typename _Fn, typename _Signature
+ = __function_guide_t<_Fn, decltype(&_Fn::operator())>>
+ function(_Fn) -> function<_Signature>;
#endif
// [20.7.15.2.6] null pointer comparisons
diff --git a/libstdc++-v3/include/std/functional b/libstdc++-v3/include/std/functional
index c4f7588..5235ef2 100644
--- a/libstdc++-v3/include/std/functional
+++ b/libstdc++-v3/include/std/functional
@@ -465,6 +465,17 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
/// @endcond
+#if __cplusplus == 201703L && _GLIBCXX_USE_DEPRECATED
+# define _GLIBCXX_VOLATILE_BIND
+// _GLIBCXX_RESOLVE_LIB_DEFECTS
+// 2487. bind() should be const-overloaded, not cv-overloaded
+# define _GLIBCXX_DEPR_BIND \
+ [[deprecated("std::bind does not support volatile in C++17")]]
+#elif __cplusplus < 201703L
+# define _GLIBCXX_VOLATILE_BIND
+# define _GLIBCXX_DEPR_BIND
+#endif
+
/// Type of the function object returned from bind().
template<typename _Signature>
class _Bind;
@@ -501,6 +512,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
);
}
+#ifdef _GLIBCXX_VOLATILE_BIND
// Call as volatile
template<typename _Result, typename... _Args, std::size_t... _Indexes>
_Result
@@ -522,6 +534,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
_Mu<_Bound_args>()(__volget<_Indexes>(_M_bound_args), __args)...
);
}
+#endif // volatile
template<typename _BoundArg, typename _CallArgs>
using _Mu_type = decltype(
@@ -585,12 +598,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
_Bound_indexes());
}
-#if __cplusplus > 201402L
-# define _GLIBCXX_DEPR_BIND \
- [[deprecated("std::bind does not support volatile in C++17")]]
-#else
-# define _GLIBCXX_DEPR_BIND
-#endif
+#ifdef _GLIBCXX_VOLATILE_BIND
// Call as volatile
template<typename... _Args,
typename _Result = _Res_type_cv<tuple<_Args...>, add_volatile>>
@@ -614,6 +622,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
std::forward_as_tuple(std::forward<_Args>(__args)...),
_Bound_indexes());
}
+#endif // volatile
};
/// Type of the function object returned from bind<R>().
@@ -649,9 +658,9 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
(std::get<_Indexes>(_M_bound_args), __args)...);
}
+#ifdef _GLIBCXX_VOLATILE_BIND
// Call as volatile
template<typename _Res, typename... _Args, std::size_t... _Indexes>
- _GLIBCXX20_CONSTEXPR
_Res
__call(tuple<_Args...>&& __args, _Index_tuple<_Indexes...>) volatile
{
@@ -661,7 +670,6 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
// Call as const volatile
template<typename _Res, typename... _Args, std::size_t... _Indexes>
- _GLIBCXX20_CONSTEXPR
_Res
__call(tuple<_Args...>&& __args,
_Index_tuple<_Indexes...>) const volatile
@@ -669,6 +677,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
return std::__invoke_r<_Res>(_M_f, _Mu<_Bound_args>()
(__volget<_Indexes>(_M_bound_args), __args)...);
}
+#endif // volatile
public:
typedef _Result result_type;
@@ -710,6 +719,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
_Bound_indexes());
}
+#ifdef _GLIBCXX_VOLATILE_BIND
// Call as volatile
template<typename... _Args>
_GLIBCXX_DEPR_BIND
@@ -731,7 +741,13 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
std::forward_as_tuple(std::forward<_Args>(__args)...),
_Bound_indexes());
}
+#else
+ template<typename... _Args>
+ void operator()(_Args&&...) const volatile = delete;
+#endif // volatile
};
+
+#undef _GLIBCXX_VOLATILE_BIND
#undef _GLIBCXX_DEPR_BIND
/**
diff --git a/libstdc++-v3/include/std/future b/libstdc++-v3/include/std/future
index a1b2d7f..cf08c15 100644
--- a/libstdc++-v3/include/std/future
+++ b/libstdc++-v3/include/std/future
@@ -1649,8 +1649,8 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
template<typename _Res, typename... _ArgTypes>
packaged_task(_Res(*)(_ArgTypes...)) -> packaged_task<_Res(_ArgTypes...)>;
- template<typename _Fun, typename _Signature = typename
- __function_guide_helper<decltype(&_Fun::operator())>::type>
+ template<typename _Fun, typename _Signature
+ = __function_guide_t<_Fun, decltype(&_Fun::operator())>>
packaged_task(_Fun) -> packaged_task<_Signature>;
#endif
diff --git a/libstdc++-v3/include/std/type_traits b/libstdc++-v3/include/std/type_traits
index c5853fc..22c1af2 100644
--- a/libstdc++-v3/include/std/type_traits
+++ b/libstdc++-v3/include/std/type_traits
@@ -1381,6 +1381,12 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
: public integral_constant<bool, __is_base_of(_Base, _Derived)>
{ };
+#if __has_builtin(__is_convertible)
+ template<typename _From, typename _To>
+ struct is_convertible
+ : public __bool_constant<__is_convertible(_From, _To)>
+ { };
+#else
template<typename _From, typename _To,
bool = __or_<is_void<_From>, is_function<_To>,
is_array<_To>>::value>
@@ -1416,12 +1422,28 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
struct is_convertible
: public __is_convertible_helper<_From, _To>::type
{ };
+#endif
// helper trait for unique_ptr<T[]>, shared_ptr<T[]>, and span<T, N>
template<typename _ToElementType, typename _FromElementType>
using __is_array_convertible
= is_convertible<_FromElementType(*)[], _ToElementType(*)[]>;
+#if __cplusplus >= 202002L
+#define __cpp_lib_is_nothrow_convertible 201806L
+
+#if __has_builtin(__is_nothrow_convertible)
+ /// is_nothrow_convertible_v
+ template<typename _From, typename _To>
+ inline constexpr bool is_nothrow_convertible_v
+ = __is_nothrow_convertible(_From, _To);
+
+ /// is_nothrow_convertible
+ template<typename _From, typename _To>
+ struct is_nothrow_convertible
+ : public bool_constant<is_nothrow_convertible_v<_From, _To>>
+ { };
+#else
template<typename _From, typename _To,
bool = __or_<is_void<_From>, is_function<_To>,
is_array<_To>>::value>
@@ -1451,8 +1473,6 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
};
#pragma GCC diagnostic pop
-#if __cplusplus > 201703L
-#define __cpp_lib_is_nothrow_convertible 201806L
/// is_nothrow_convertible
template<typename _From, typename _To>
struct is_nothrow_convertible
@@ -1463,6 +1483,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
template<typename _From, typename _To>
inline constexpr bool is_nothrow_convertible_v
= is_nothrow_convertible<_From, _To>::value;
+#endif
#endif // C++2a
// Const-volatile modifications.
@@ -2843,7 +2864,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
struct __is_invocable_impl
: false_type
{
- using __nothrow_type = false_type; // For is_nothrow_invocable_r
+ using __nothrow_conv = false_type; // For is_nothrow_invocable_r
};
// Used for valid INVOKE and INVOKE<void> expressions.
@@ -2853,7 +2874,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
__void_t<typename _Result::type>>
: true_type
{
- using __nothrow_type = true_type; // For is_nothrow_invocable_r
+ using __nothrow_conv = true_type; // For is_nothrow_invocable_r
};
#pragma GCC diagnostic push
@@ -2866,18 +2887,22 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
{
private:
// The type of the INVOKE expression.
+ using _Res_t = typename _Result::type;
+
// Unlike declval, this doesn't add_rvalue_reference, so it respects
// guaranteed copy elision.
- static typename _Result::type _S_get() noexcept;
+ static _Res_t _S_get() noexcept;
+ // Used to check if _Res_t can implicitly convert to _Tp.
template<typename _Tp>
- static void _S_conv(_Tp) noexcept;
+ static void _S_conv(__type_identity_t<_Tp>) noexcept;
// This overload is viable if INVOKE(f, args...) can convert to _Tp.
- template<typename _Tp, bool _Check_Noex = false,
+ template<typename _Tp,
+ bool _Nothrow = noexcept(_S_conv<_Tp>(_S_get())),
typename = decltype(_S_conv<_Tp>(_S_get())),
- bool _Noex = noexcept(_S_conv<_Tp>(_S_get()))>
- static __bool_constant<_Check_Noex ? _Noex : true>
+ bool _Dangle = __reference_converts_from_temporary(_Tp, _Res_t)>
+ static __bool_constant<_Nothrow && !_Dangle>
_S_test(int);
template<typename _Tp, bool = false>
@@ -2886,10 +2911,10 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
public:
// For is_invocable_r
- using type = decltype(_S_test<_Ret>(1));
+ using type = decltype(_S_test<_Ret, /* Nothrow = */ true>(1));
// For is_nothrow_invocable_r
- using __nothrow_type = decltype(_S_test<_Ret, true>(1));
+ using __nothrow_conv = decltype(_S_test<_Ret>(1));
};
#pragma GCC diagnostic pop
@@ -3020,9 +3045,12 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
};
/// @cond undocumented
+ // This checks that the INVOKE<R> expression is well-formed and that the
+ // conversion to R does not throw. It does *not* check whether the INVOKE
+ // expression itself can throw. That is done by __call_is_nothrow_ instead.
template<typename _Result, typename _Ret>
using __is_nt_invocable_impl
- = typename __is_invocable_impl<_Result, _Ret>::__nothrow_type;
+ = typename __is_invocable_impl<_Result, _Ret>::__nothrow_conv;
/// @endcond
/// std::is_nothrow_invocable_r
@@ -3265,7 +3293,7 @@ template <typename _Tp>
template <typename _Base, typename _Derived>
inline constexpr bool is_base_of_v = __is_base_of(_Base, _Derived);
template <typename _From, typename _To>
- inline constexpr bool is_convertible_v = is_convertible<_From, _To>::value;
+ inline constexpr bool is_convertible_v = __is_convertible(_From, _To);
template<typename _Fn, typename... _Args>
inline constexpr bool is_invocable_v = is_invocable<_Fn, _Args...>::value;
template<typename _Fn, typename... _Args>
diff --git a/libstdc++-v3/testsuite/20_util/bind/cv_quals.cc b/libstdc++-v3/testsuite/20_util/bind/cv_quals.cc
index 8331239..79e3e2f 100644
--- a/libstdc++-v3/testsuite/20_util/bind/cv_quals.cc
+++ b/libstdc++-v3/testsuite/20_util/bind/cv_quals.cc
@@ -17,6 +17,7 @@
// 20.7.11 Function template bind
+// { dg-options "-Wdeprecated-declarations" }
// { dg-do run { target c++11 } }
#include <functional>
@@ -48,12 +49,12 @@ void test01()
const auto b1 = std::bind(X());
VERIFY( b1() == 1 );
-#if __cplusplus <= 201402L
+#if __cplusplus <= 201703L
volatile auto b2 = std::bind(X());
- VERIFY( b2() == 2 );
+ VERIFY( b2() == 2 ); // { dg-warning "deprecated" "" { target c++17_only } }
const volatile auto b3 = std::bind(X());
- VERIFY( b3() == 3 );
+ VERIFY( b3() == 3 ); // { dg-warning "deprecated" "" { target c++17_only } }
#endif
}
@@ -65,12 +66,12 @@ void test02()
const auto b1 = std::bind<int>(X());
VERIFY( b1() == 1 );
-#if __cplusplus <= 201402L
+#if __cplusplus <= 201703L
volatile auto b2 = std::bind<int>(X());
- VERIFY( b2() == 2 );
+ VERIFY( b2() == 2 ); // { dg-warning "deprecated" "" { target c++17_only } }
const volatile auto b3 = std::bind<int>(X());
- VERIFY( b3() == 3 );
+ VERIFY( b3() == 3 ); // { dg-warning "deprecated" "" { target c++17_only } }
#endif
}
@@ -82,12 +83,12 @@ void test03()
const auto b1 = std::bind(X(), _1, 0, _2);
VERIFY( b1(0, 0) == 1 );
-#if __cplusplus <= 201402L
+#if __cplusplus <= 201703L
volatile auto b2 = std::bind(X(), _1, _2, 0);
- VERIFY( b2(0, 0) == 2 );
+ VERIFY( b2(0, 0) == 2 ); // { dg-warning "deprecated" "" { target c++17_only } }
const volatile auto b3 = std::bind(X(), _1, 0, _2);
- VERIFY( b3(0, 0) == 3 );
+ VERIFY( b3(0, 0) == 3 ); // { dg-warning "deprecated" "" { target c++17_only } }
#endif
}
@@ -99,12 +100,12 @@ void test04()
const auto b1 = std::bind<int>(X(), _1, 0, _2);
VERIFY( b1(0, 0) == 1 );
-#if __cplusplus <= 201402L
+#if __cplusplus <= 201703L
volatile auto b2 = std::bind<int>(X(), _1, _2, 0);
- VERIFY( b2(0, 0) == 2 );
+ VERIFY( b2(0, 0) == 2 ); // { dg-warning "deprecated" "" { target c++17_only } }
const volatile auto b3 = std::bind<int>(X(), _1, 0, _2);
- VERIFY( b3(0, 0) == 3 );
+ VERIFY( b3(0, 0) == 3 ); // { dg-warning "deprecated" "" { target c++17_only } }
#endif
}
diff --git a/libstdc++-v3/testsuite/20_util/bind/cv_quals_2.cc b/libstdc++-v3/testsuite/20_util/bind/cv_quals_2.cc
index 7a85568..d2ebad72 100644
--- a/libstdc++-v3/testsuite/20_util/bind/cv_quals_2.cc
+++ b/libstdc++-v3/testsuite/20_util/bind/cv_quals_2.cc
@@ -15,7 +15,9 @@
// with this library; see the file COPYING3. If not see
// <http://www.gnu.org/licenses/>.
-// { dg-do run { target c++11 } }
+// { dg-options "-Wdeprecated-declarations" }
+// { dg-do run { target { c++11 && c++17_down } } }
+// { dg-do compile { target c++20 } }
#include <functional>
#include <testsuite_hooks.h>
@@ -33,13 +35,13 @@ void test01()
const auto b0 = std::bind(X());
VERIFY( b0() == 0 );
-#if __cplusplus <= 201402L
volatile auto b1 = std::bind(X());
- VERIFY( b1() == 1 );
+ VERIFY( b1() == 1 ); // { dg-warning "deprecated" "" { target c++17_only } }
+ // { dg-error "no match" "" { target c++20 } 39 }
const volatile auto b2 = std::bind(X());
- VERIFY( b2() == 2 );
-#endif
+ VERIFY( b2() == 2 ); // { dg-warning "deprecated" "" { target c++17_only } }
+ // { dg-error "no match" "" { target c++20 } 43 }
}
int main()
diff --git a/libstdc++-v3/testsuite/20_util/bind/dangling_ref.cc b/libstdc++-v3/testsuite/20_util/bind/dangling_ref.cc
new file mode 100644
index 0000000..70393e4
--- /dev/null
+++ b/libstdc++-v3/testsuite/20_util/bind/dangling_ref.cc
@@ -0,0 +1,9 @@
+// { dg-do compile { target c++11 } }
+#include <functional>
+
+int f();
+auto b = std::bind<const int&>(f);
+int i = b(); // { dg-error "here" "" { target { c++14_down } } }
+// { dg-error "dangling reference" "" { target { c++14_down } } 0 }
+// { dg-error "no matching function" "" { target c++17 } 0 }
+// { dg-error "enable_if" "" { target c++17 } 0 }
diff --git a/libstdc++-v3/testsuite/20_util/function/cons/70692.cc b/libstdc++-v3/testsuite/20_util/function/cons/70692.cc
new file mode 100644
index 0000000..7cdc472
--- /dev/null
+++ b/libstdc++-v3/testsuite/20_util/function/cons/70692.cc
@@ -0,0 +1,13 @@
+// { dg-do compile { target c++11 } }
+// PR libstdc++/70692
+// No warning when function<const int&(...)> binds a reference to a temporary
+#include <functional>
+
+int f();
+
+int main()
+{
+ std::function<const int&()> ff(f); // { dg-error "no matching function" }
+ std::function<long&&()> f2(f); // { dg-error "no matching function" }
+}
+// { dg-error "std::enable_if" "" { target *-*-* } 0 }
diff --git a/libstdc++-v3/testsuite/20_util/function/cons/deduction_c++23.cc b/libstdc++-v3/testsuite/20_util/function/cons/deduction_c++23.cc
new file mode 100644
index 0000000..17454ea
--- /dev/null
+++ b/libstdc++-v3/testsuite/20_util/function/cons/deduction_c++23.cc
@@ -0,0 +1,23 @@
+// { dg-options "-std=gnu++23" }
+// { dg-do compile { target c++23 } }
+
+#include <functional>
+
+template<typename T, typename U> struct require_same;
+template<typename T> struct require_same<T, T> { using type = void; };
+
+template<typename T, typename U>
+ typename require_same<T, U>::type
+ check_type(U&) { }
+
+void
+test_static_call_operator()
+{
+ struct F1 { static long operator()() { return 0; } };
+ std::function func1 = F1{};
+ check_type<std::function<long()>>(func1);
+
+ struct F2 { static float operator()(char, void*) noexcept { return 0; } };
+ std::function func2 = F2{};
+ check_type<std::function<float(char, void*)>>(func2);
+}
diff --git a/libstdc++-v3/testsuite/20_util/function_objects/invoke/dangling_ref.cc b/libstdc++-v3/testsuite/20_util/function_objects/invoke/dangling_ref.cc
new file mode 100644
index 0000000..1513480
--- /dev/null
+++ b/libstdc++-v3/testsuite/20_util/function_objects/invoke/dangling_ref.cc
@@ -0,0 +1,12 @@
+// { dg-options "-std=gnu++23" }
+// { dg-do compile { target c++23 } }
+#include <functional>
+
+int f();
+
+template<typename R>
+concept can_invoke = requires (int (&f)()) { std::invoke_r<R>(f); };
+
+static_assert( not can_invoke<const int&> );
+static_assert( not can_invoke<int&&> );
+static_assert( not can_invoke<const long&> );
diff --git a/libstdc++-v3/testsuite/20_util/is_convertible/requirements/access.cc b/libstdc++-v3/testsuite/20_util/is_convertible/requirements/access.cc
new file mode 100644
index 0000000..04a8c52
--- /dev/null
+++ b/libstdc++-v3/testsuite/20_util/is_convertible/requirements/access.cc
@@ -0,0 +1,18 @@
+// { dg-do compile { target c++11 } }
+// PR c++/107049
+
+#include <type_traits>
+
+class Private
+{
+ operator int() const
+ {
+ static_assert( not std::is_convertible<Private, int>::value, "" );
+#if __cpp_lib_type_trait_variable_templates
+ static_assert( not std::is_convertible_v<Private, int>, "" );
+#endif
+ return 0;
+ }
+};
+
+static_assert( not std::is_convertible<Private, int>::value, "" );
diff --git a/libstdc++-v3/testsuite/20_util/is_invocable/dangling_ref.cc b/libstdc++-v3/testsuite/20_util/is_invocable/dangling_ref.cc
new file mode 100644
index 0000000..46719b9
--- /dev/null
+++ b/libstdc++-v3/testsuite/20_util/is_invocable/dangling_ref.cc
@@ -0,0 +1,6 @@
+// { dg-do compile { target c++17 } }
+#include <type_traits>
+
+static_assert( not std::is_invocable_r_v<const int&, int()> );
+static_assert( not std::is_invocable_r_v<int&&, int()> );
+static_assert( not std::is_invocable_r_v<const long&, int()> );
diff --git a/libstdc++-v3/testsuite/20_util/pointer_traits/lwg3545.cc b/libstdc++-v3/testsuite/20_util/pointer_traits/lwg3545.cc
index 08c3ed0..93c64a3 100644
--- a/libstdc++-v3/testsuite/20_util/pointer_traits/lwg3545.cc
+++ b/libstdc++-v3/testsuite/20_util/pointer_traits/lwg3545.cc
@@ -99,3 +99,20 @@ static_assert( is_same<pointer<Ctraits>, clever_ptr<char>>::value, "" );
static_assert( is_same<difference_type<Ctraits>, std::ptrdiff_t>::value, "" );
static_assert( is_same<rebind<Ctraits>, clever_ptr<short>>::value, "" );
static_assert( is_same<pointer_to<Ctraits>, clever_ptr<char>>::value, "" );
+
+#ifdef __cpp_concepts
+struct ptr_base { };
+
+// Program-defined specialization must not be ambiguous with primary template.
+template<typename P> requires std::derived_from<P, ptr_base>
+struct std::pointer_traits<P>
+{
+ using element_type = int;
+ using difference_type = long;
+ using pointer = P;
+};
+
+struct Ptr : ptr_base { using element_type = int; };
+
+using E = std::pointer_traits<Ptr>::element_type;
+#endif
diff --git a/libstdc++-v3/testsuite/30_threads/packaged_task/cons/dangling_ref.cc b/libstdc++-v3/testsuite/30_threads/packaged_task/cons/dangling_ref.cc
new file mode 100644
index 0000000..e9edb5e
--- /dev/null
+++ b/libstdc++-v3/testsuite/30_threads/packaged_task/cons/dangling_ref.cc
@@ -0,0 +1,11 @@
+// { dg-do compile { target c++11 } }
+#include <future>
+
+// C++20 [futures.task.members]
+// Mandates: is_invocable_r_v<R, F&, ArgTypes...> is true.
+
+int f();
+std::packaged_task<const int&()> task(f);
+// { dg-error "dangling reference" "" { target { c++14_down } } 0 }
+// { dg-error "no matching function" "" { target c++17 } 0 }
+// { dg-error "enable_if" "" { target c++17 } 0 }
diff --git a/libstdc++-v3/testsuite/30_threads/packaged_task/cons/deduction_c++23.cc b/libstdc++-v3/testsuite/30_threads/packaged_task/cons/deduction_c++23.cc
new file mode 100644
index 0000000..e36edfa0
--- /dev/null
+++ b/libstdc++-v3/testsuite/30_threads/packaged_task/cons/deduction_c++23.cc
@@ -0,0 +1,23 @@
+// { dg-options "-std=gnu++23" }
+// { dg-do compile { target c++23 } }
+
+#include <future>
+
+template<typename T, typename U> struct require_same;
+template<typename T> struct require_same<T, T> { using type = void; };
+
+template<typename T, typename U>
+ typename require_same<T, U>::type
+ check_type(U&) { }
+
+void
+test_static_call_operator()
+{
+ struct F1 { static long operator()() { return 0; } };
+ std::packaged_task task1{ F1{} };
+ check_type<std::packaged_task<long()>>(task1);
+
+ struct F2 { static float operator()(char, void*) noexcept { return 0; } };
+ std::packaged_task task2{ F2{} };
+ check_type<std::packaged_task<float(char, void*)>>(task2);
+}