From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 2181) id 434793858C53; Tue, 26 Apr 2022 13:11:39 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 434793858C53 MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="utf-8" From: Jonathan Wakely To: gcc-cvs@gcc.gnu.org, libstdc++-cvs@gcc.gnu.org Subject: [gcc r10-10558] libstdc++: Fix non-reserved name in header X-Act-Checkin: gcc X-Git-Author: Jonathan Wakely X-Git-Refname: refs/heads/releases/gcc-10 X-Git-Oldrev: 00f1e01f9d47f7bdcc24aa11858ae629442a7afa X-Git-Newrev: b072b2f85aaa3f6d27c706b80f521335c675f63e Message-Id: <20220426131139.434793858C53@sourceware.org> Date: Tue, 26 Apr 2022 13:11:39 +0000 (GMT) X-BeenThere: libstdc++-cvs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libstdc++-cvs mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Apr 2022 13:11:39 -0000 https://gcc.gnu.org/g:b072b2f85aaa3f6d27c706b80f521335c675f63e commit r10-10558-gb072b2f85aaa3f6d27c706b80f521335c675f63e Author: Jonathan Wakely Date: Mon Dec 13 13:36:33 2021 +0000 libstdc++: Fix non-reserved name in header libstdc++-v3/ChangeLog: * include/bits/regex_compiler.tcc (_Compiler::_M_match_token): Use reserved name for parameter. * testsuite/17_intro/names.cc: Check "token". (cherry picked from commit b0e6a257f1862e217cdf19332ea0f7bad56dcddc) Diff: --- libstdc++-v3/include/bits/regex_compiler.tcc | 4 ++-- libstdc++-v3/testsuite/17_intro/names.cc | 1 + 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/libstdc++-v3/include/bits/regex_compiler.tcc b/libstdc++-v3/include/bits/regex_compiler.tcc index 2ae4af02c89..d29a0537283 100644 --- a/libstdc++-v3/include/bits/regex_compiler.tcc +++ b/libstdc++-v3/include/bits/regex_compiler.tcc @@ -586,9 +586,9 @@ namespace __detail template bool _Compiler<_TraitsT>:: - _M_match_token(_TokenT token) + _M_match_token(_TokenT __token) { - if (token == _M_scanner._M_get_token()) + if (__token == _M_scanner._M_get_token()) { _M_value = _M_scanner._M_get_value(); _M_scanner._M_advance(); diff --git a/libstdc++-v3/testsuite/17_intro/names.cc b/libstdc++-v3/testsuite/17_intro/names.cc index 7d3960e3843..f60c70ef561 100644 --- a/libstdc++-v3/testsuite/17_intro/names.cc +++ b/libstdc++-v3/testsuite/17_intro/names.cc @@ -107,6 +107,7 @@ #define tmp ( #define sz ( +#define token ( #if __cplusplus < 201103L #define uses_allocator (