From: Hannes Domani <ssbssa@yahoo.de>
To: gdb-patches@sourceware.org
Subject: [PATCH 2/4] Don't use auto for lambda parameter
Date: Mon, 28 Nov 2022 20:12:22 +0100 [thread overview]
Message-ID: <20221128191224.1411-2-ssbssa@yahoo.de> (raw)
In-Reply-To: <20221128191224.1411-1-ssbssa@yahoo.de>
Older gcc versions (here 4.9.2) can't handle auto for a lambda parameter:
../../gdb/windows-nat.c: In member function 'void windows_nat_target::delete_thread(ptid_t, DWORD, bool)':
../../gdb/windows-nat.c:629:12: error: use of 'auto' in lambda parameter declaration only available with -std=c++1y or -std=gnu++1y [-Werror]
[=] (auto &th)
^
---
gdb/windows-nat.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/gdb/windows-nat.c b/gdb/windows-nat.c
index f61f6c1cb35..6da6757acaf 100644
--- a/gdb/windows-nat.c
+++ b/gdb/windows-nat.c
@@ -631,7 +631,7 @@ windows_nat_target::delete_thread (ptid_t ptid, DWORD exit_code,
auto iter = std::find_if (windows_process.thread_list.begin (),
windows_process.thread_list.end (),
- [=] (auto &th)
+ [=] (std::unique_ptr<windows_thread_info> &th)
{
return th->tid == id;
});
--
2.35.1
next prev parent reply other threads:[~2022-11-28 19:10 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20221128191224.1411-1-ssbssa.ref@yahoo.de>
2022-11-28 19:12 ` [PATCH 1/4] Fix calling convention of thread entry point Hannes Domani
2022-11-28 19:12 ` Hannes Domani [this message]
2022-11-28 19:25 ` [PATCH 2/4] Don't use auto for lambda parameter Tom Tromey
2022-11-28 19:12 ` [PATCH 3/4] Actually set m_is_async to current async mode Hannes Domani
2022-11-28 19:26 ` Tom Tromey
2022-11-28 19:12 ` [PATCH 4/4] Remove no longer used jump label Hannes Domani
2022-11-28 19:35 ` Tom Tromey
2022-11-28 19:24 ` [PATCH 1/4] Fix calling convention of thread entry point Tom Tromey
2022-11-28 19:45 ` Hannes Domani
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=20221128191224.1411-2-ssbssa@yahoo.de \
--to=ssbssa@yahoo.de \
--cc=gdb-patches@sourceware.org \
/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).