public inbox for libstdc++@gcc.gnu.org
 help / color / mirror / Atom feed
From: Jonathan Wakely <jwakely@redhat.com>
To: Thomas Rodgers <trodgers@redhat.com>
Cc: gcc-patches@gcc.gnu.org, libstdc++@gcc.gnu.org
Subject: Re: [PATCH] Add feature test macro for atomic<T>::wait
Date: Wed, 2 Dec 2020 00:41:31 +0000	[thread overview]
Message-ID: <20201202004131.GN2309743@redhat.com> (raw)
In-Reply-To: <xkqeeek9gkeu.fsf@trodgers.remote>

[-- Attachment #1: Type: text/plain, Size: 206 bytes --]

On 01/12/20 15:45 -0800, Thomas Rodgers via Libstdc++ wrote:
>Tested x86_64-pc-linux-gnu, committed to trunk.

This does a couple more #ifdef -> #if changes.

Tested powerpc64le-linux, committed to trunk.


[-- Attachment #2: patch.txt --]
[-- Type: text/x-patch, Size: 2016 bytes --]

commit 670f5095e4aacc30099f6b73c1e67c06df76f36b
Author: Jonathan Wakely <jwakely@redhat.com>
Date:   Wed Dec 2 00:39:22 2020

    libstdc++: Make preprocessor checks for __cpp_lib_atomic_wait consistent
    
    This changes some #ifdef checks to use #if instead.
    
    libstdc++-v3/ChangeLog:
    
            * include/bits/atomic_timed_wait.h: Use #if instead of #ifdef.
            * include/bits/semaphore_base.h: Likewise.
            * include/std/version: Remove trailing whitespace.

diff --git a/libstdc++-v3/include/bits/atomic_timed_wait.h b/libstdc++-v3/include/bits/atomic_timed_wait.h
index 6dd1a145e69..83438ae31ed 100644
--- a/libstdc++-v3/include/bits/atomic_timed_wait.h
+++ b/libstdc++-v3/include/bits/atomic_timed_wait.h
@@ -34,7 +34,7 @@
 
 #include <bits/atomic_wait.h>
 
-#ifdef __cpp_lib_atomic_wait
+#if __cpp_lib_atomic_wait
 #include <bits/functional_hash.h>
 
 #include <chrono>
diff --git a/libstdc++-v3/include/bits/semaphore_base.h b/libstdc++-v3/include/bits/semaphore_base.h
index 0ed1f5895af..e4e57de4acf 100644
--- a/libstdc++-v3/include/bits/semaphore_base.h
+++ b/libstdc++-v3/include/bits/semaphore_base.h
@@ -33,7 +33,7 @@
 #pragma GCC system_header
 
 #include <bits/atomic_base.h>
-#ifdef __cpp_lib_atomic_wait 
+#if __cpp_lib_atomic_wait
 #include <bits/atomic_timed_wait.h>
 
 #include <ext/numeric_traits.h>
diff --git a/libstdc++-v3/include/std/version b/libstdc++-v3/include/std/version
index 4bb45b7805c..25f628f399d 100644
--- a/libstdc++-v3/include/std/version
+++ b/libstdc++-v3/include/std/version
@@ -219,7 +219,7 @@
 #ifdef _GLIBCXX_HAS_GTHREADS
 # define __cpp_lib_jthread 201911L
 #endif
-#if __cpp_lib_atomic_wait 
+#if __cpp_lib_atomic_wait
 # define __cpp_lib_latch 201907L
 #endif
 #define __cpp_lib_list_remove_return_type 201806L
@@ -231,7 +231,7 @@
 #if __cpp_lib_concepts
 # define __cpp_lib_ranges 201911L
 #endif
-#if __cpp_lib_atomic_wait 
+#if __cpp_lib_atomic_wait
 # define __cpp_lib_semaphore 201907L
 #endif
 #define __cpp_lib_shift 201806L

      reply	other threads:[~2020-12-02  0:41 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-11-30 18:17 Thomas Rodgers
2020-12-01 14:52 ` Jonathan Wakely
2020-12-01 23:45   ` Thomas Rodgers
2020-12-02  0:41     ` Jonathan Wakely [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20201202004131.GN2309743@redhat.com \
    --to=jwakely@redhat.com \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=libstdc++@gcc.gnu.org \
    --cc=trodgers@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).