aboutsummaryrefslogtreecommitdiff
path: root/gcc/cppdefault.c
diff options
context:
space:
mode:
authorJonathan Wakely <jwakely@redhat.com>2020-11-11 09:28:50 +0000
committerJonathan Wakely <jwakely@redhat.com>2020-11-11 11:13:31 +0000
commit43f9e5aff06f1ca2296fdbd3141fe90ec0be1912 (patch)
treefb776ac5597767d4a388a1536d6175f0ae942a4b /gcc/cppdefault.c
parentca813880dcaae71f664d8f386b1a584cfefbbd4b (diff)
downloadgcc-43f9e5aff06f1ca2296fdbd3141fe90ec0be1912.zip
gcc-43f9e5aff06f1ca2296fdbd3141fe90ec0be1912.tar.gz
gcc-43f9e5aff06f1ca2296fdbd3141fe90ec0be1912.tar.bz2
libstdc++: Use helper type for checking thread ID
This encapsulates the storing and checking of the thread ID into a class type, so that the macro _GLIBCXX_HAS_GTHREADS is only checked in one place. The code doing the checks just calls member functions of the new type, without caring whether that really does any work or not. libstdc++-v3/ChangeLog: * include/std/stop_token (_Stop_state_t::_M_requester): Define new struct with members to store and check the thread ID. (_Stop_state_t::_M_request_stop()): Use _M_requester._M_set(). (_Stop_state_t::_M_remove_callback(_Stop_cb*)): Use _M_requester._M_is_current_thread().
Diffstat (limited to 'gcc/cppdefault.c')
0 files changed, 0 insertions, 0 deletions