From: "Tom Tromey (Code Review)" <gerrit@gnutoolchain-gerrit.osci.io>
To: Christian Biesinger <cbiesinger@google.com>, gdb-patches@sourceware.org
Subject: [review] Replace bsearch with a std::lower_bound-based search
Date: Tue, 29 Oct 2019 19:01:00 -0000 [thread overview]
Message-ID: <20191029190048.B0B7E20AF6@gnutoolchain-gerrit.osci.io> (raw)
In-Reply-To: <gerrit.1572317588000.I07e0a0e333f4062b27fc68d3a3f24881ebc68fd4@gnutoolchain-gerrit.osci.io>
Tom Tromey has posted comments on this change.
Change URL: https://gnutoolchain-gerrit.osci.io/r/c/binutils-gdb/+/403
......................................................................
Patch Set 1: Code-Review+2
(1 comment)
Thank you for the patch.
I found one nit. The patch is ok with this fixed.
No need to re-review.
https://gnutoolchain-gerrit.osci.io/r/c/binutils-gdb/+/403/1/gdb/gdbsupport/gdb_binary_search.h
File gdb/gdbsupport/gdb_binary_search.h:
https://gnutoolchain-gerrit.osci.io/r/c/binutils-gdb/+/403/1/gdb/gdbsupport/gdb_binary_search.h@44
PS1, Line 44:
36 | b, respectively.
37 | [first, last) must be sorted.
38 |
39 | The return value is an iterator pointing to the found element, or LAST if
40 | no element was found. */
41 | template<typename It, typename T, typename Comp>
42 | It binary_search (It first, It last, T el, Comp comp)
43 | {
44 | auto lt = [&] (const typename std::iterator_traits<It>::value_type& a,
45 | const T& b)
The "&"s are in the wrong spots here.
--
Gerrit-Project: binutils-gdb
Gerrit-Branch: master
Gerrit-Change-Id: I07e0a0e333f4062b27fc68d3a3f24881ebc68fd4
Gerrit-Change-Number: 403
Gerrit-PatchSet: 1
Gerrit-Owner: Christian Biesinger <cbiesinger@google.com>
Gerrit-Reviewer: Tom Tromey <tromey@sourceware.org>
Gerrit-Comment-Date: Tue, 29 Oct 2019 19:00:48 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment
next prev parent reply other threads:[~2019-10-29 19:01 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-10-29 2:53 Christian Biesinger (Code Review)
2019-10-29 19:01 ` Tom Tromey (Code Review) [this message]
2019-10-29 19:07 ` [pushed] " Sourceware to Gerrit sync (Code Review)
2019-10-29 19:07 ` [review] " Christian Biesinger (Code Review)
2019-10-29 19:07 ` [pushed] " Sourceware to Gerrit sync (Code Review)
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=20191029190048.B0B7E20AF6@gnutoolchain-gerrit.osci.io \
--to=gerrit@gnutoolchain-gerrit.osci.io \
--cc=cbiesinger@google.com \
--cc=gdb-patches@sourceware.org \
--cc=gnutoolchain-gerrit@osci.io \
/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