public inbox for libstdc++-cvs@sourceware.org
help / color / mirror / Atom feed
* [gcc(refs/users/giulianob/heads/autopar_rebase2)] libstdc++, coroutine: Add missing constexpr markers.
@ 2020-08-18  0:58 Giuliano Belinassi
  0 siblings, 0 replies; only message in thread
From: Giuliano Belinassi @ 2020-08-18  0:58 UTC (permalink / raw)
  To: gcc-cvs, libstdc++-cvs

https://gcc.gnu.org/g:1157829f23bf56bcd08761c0368de7343284431b

commit 1157829f23bf56bcd08761c0368de7343284431b
Author: Iain Sandoe <iain@sandoe.co.uk>
Date:   Sun Jul 12 20:16:21 2020 +0100

    libstdc++, coroutine: Add missing constexpr markers.
    
    The methods of the trivial awaitables are intended to
    be constexpr.
    
    libstdc++-v3/ChangeLog:
    
            * include/std/coroutine: Mark the methods of the
            trivial awaitables as constexpr.

Diff:
---
 libstdc++-v3/include/std/coroutine | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/libstdc++-v3/include/std/coroutine b/libstdc++-v3/include/std/coroutine
index b40a3bcf9cc..468d1107557 100644
--- a/libstdc++-v3/include/std/coroutine
+++ b/libstdc++-v3/include/std/coroutine
@@ -273,20 +273,20 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
   /// [coroutine.trivial.awaitables]
   struct suspend_always
   {
-    bool await_ready() { return false; }
+    constexpr bool await_ready() const noexcept { return false; }
 
-    void await_suspend(coroutine_handle<>) {}
+    constexpr void await_suspend(coroutine_handle<>) const noexcept {}
 
-    void await_resume() {}
+    constexpr void await_resume() const noexcept {}
   };
 
   struct suspend_never
   {
-    bool await_ready() { return true; }
+    constexpr bool await_ready() const noexcept { return true; }
 
-    void await_suspend(coroutine_handle<>) {}
+    constexpr void await_suspend(coroutine_handle<>) const noexcept {}
 
-    void await_resume() {}
+    constexpr void await_resume() const noexcept {}
   };
 
   } // namespace __n4861


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2020-08-18  0:58 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-08-18  0:58 [gcc(refs/users/giulianob/heads/autopar_rebase2)] libstdc++, coroutine: Add missing constexpr markers Giuliano Belinassi

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).