diff options
author | Tom Tromey <tom@tromey.com> | 2025-02-21 11:57:48 -0700 |
---|---|---|
committer | Tom Tromey <tom@tromey.com> | 2025-03-07 17:15:20 -0700 |
commit | d519282866163864fff3fe0ab7227ff0339cad67 (patch) | |
tree | b0be6ac84d2013ba68f3cbafc804f8c4640837e1 /gdb/async-event.h | |
parent | c56a8d595f98b75e2c6d6575b9fb9018e150bd43 (diff) | |
download | binutils-d519282866163864fff3fe0ab7227ff0339cad67.zip binutils-d519282866163864fff3fe0ab7227ff0339cad67.tar.gz binutils-d519282866163864fff3fe0ab7227ff0339cad67.tar.bz2 |
Use wild matching for lookup_name_info::match_any
Currently, lookup_name_info::match_any symbol_name_match_type::FULL.
However, this seems wrong. Consider the expand_symtabs_matching
implementation of the cooked index: it compares name components, and
then if all the components match, it checks:
if ((match_type == symbol_name_match_type::FULL
|| (lang != language_ada
&& match_type == symbol_name_match_type::EXPRESSION)))
{
if (parent != nullptr)
continue;
That is, if the component-matching loop did not finish, and a full
match is requested, then fail to match. This handles cases where the
index is asked to look up "b::c" but finds "a::b::c".
However, match_any should match, well, any. So, it seems to me that
checking any parent matches is irrelevant -- and therefore this should
use wild matching.
Diffstat (limited to 'gdb/async-event.h')
0 files changed, 0 insertions, 0 deletions