diff options
author | Jonathan Wakely <jwakely@redhat.com> | 2020-10-08 00:05:53 +0100 |
---|---|---|
committer | Jonathan Wakely <jwakely@redhat.com> | 2020-10-08 01:36:45 +0100 |
commit | ba597a9fad83b3721c5a4d30d9fcf27f8a29eb86 (patch) | |
tree | bab48664ce367f32c6fb86f7b5cdbbf047dc188d /libstdc++-v3 | |
parent | 775c628e44e073df45e22a7b557f184e8966d05e (diff) | |
download | gcc-ba597a9fad83b3721c5a4d30d9fcf27f8a29eb86.zip gcc-ba597a9fad83b3721c5a4d30d9fcf27f8a29eb86.tar.gz gcc-ba597a9fad83b3721c5a4d30d9fcf27f8a29eb86.tar.bz2 |
libstdc++: Fix non-reserved name in header
There's a "il" parameter in a std::seed_seq constructor in <random>
which is only reserved since C++14.
libstdc++-v3/ChangeLog:
* include/bits/random.h (seed_seq(initializer_list<T>)): Rename
parameter to use reserved name.
* testsuite/17_intro/names.cc: Check "il".
(cherry picked from commit 23f75da95f5e8e09e9fcbd5b0d2885e6c44739aa)
Diffstat (limited to 'libstdc++-v3')
-rw-r--r-- | libstdc++-v3/include/bits/random.h | 2 | ||||
-rw-r--r-- | libstdc++-v3/testsuite/17_intro/names.cc | 5 |
2 files changed, 6 insertions, 1 deletions
diff --git a/libstdc++-v3/include/bits/random.h b/libstdc++-v3/include/bits/random.h index ccd5c83..50da416 100644 --- a/libstdc++-v3/include/bits/random.h +++ b/libstdc++-v3/include/bits/random.h @@ -5968,7 +5968,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION { } template<typename _IntType> - seed_seq(std::initializer_list<_IntType> il); + seed_seq(std::initializer_list<_IntType> __il); template<typename _InputIterator> seed_seq(_InputIterator __begin, _InputIterator __end); diff --git a/libstdc++-v3/testsuite/17_intro/names.cc b/libstdc++-v3/testsuite/17_intro/names.cc index dad7ba9..d758138 100644 --- a/libstdc++-v3/testsuite/17_intro/names.cc +++ b/libstdc++-v3/testsuite/17_intro/names.cc @@ -104,6 +104,11 @@ #define uses_allocator ( #endif +#if __cplusplus < 201402L +// <complex> defines operator""il +#define il ( +#endif + #if __cplusplus < 201703L // <charconv> defines to_chars_result::ptr and to_chars_result::ec #define ec ( |