]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
libstdc++: Make coroutine_handle<_Promise>::from_address() noexcept [PR 99021]
authorJonathan Wakely <jwakely@redhat.com>
Tue, 9 Feb 2021 11:23:29 +0000 (11:23 +0000)
committerJonathan Wakely <jwakely@redhat.com>
Tue, 9 Feb 2021 12:34:56 +0000 (12:34 +0000)
The coroutine_handle<void>::from_address(void*) version is already
noexcept, and they do the same thing. Make them consistent.

libstdc++-v3/ChangeLog:

PR libstdc++/99021
* include/std/coroutine (coroutine_handle<P>::from_address): Add
noexcept.

(cherry picked from commit 26a3f288f1895a8c061c0458590542a3d2ee796a)

libstdc++-v3/include/std/coroutine

index 468d11075577956e807af210c8a16b66fe64d1a5..21bdd1b2f04246f27cb8face098c74a55343c3fb 100644 (file)
@@ -197,7 +197,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
       }
 
     // 17.12.3.2, export/import
-    constexpr static coroutine_handle from_address(void* __a)
+    constexpr static coroutine_handle from_address(void* __a) noexcept
     {
       coroutine_handle __self;
       __self._M_fr_ptr = __a;