* gdb/linespec.c (find_methods): Whitespace differences aren't

significant in *un*mangled method names.  Use strcmp_iw to compare
them, not STREQ.  (Fix from Daniel Berlin.)

* gdb/testsuite/gdb.c++/userdef.exp: Check that GDB tolerates whitespace in
unmangled operator names.
This commit is contained in:
Jim Blandy 2001-03-21 20:51:16 +00:00
parent 1dffcc6638
commit 13b5765709
4 changed files with 16 additions and 1 deletions

View file

@ -1,3 +1,9 @@
2001-03-21 Jim Blandy <jimb@redhat.com>
* linespec.c (find_methods): Whitespace differences aren't
significant in *un*mangled method names. Use strcmp_iw to compare
them, not STREQ. (Fix from Daniel Berlin.)
2001-03-21 Andrew Cagney <ac131313@redhat.com>
* gdbarch.sh: Allow a non- multi-arch target to override a

View file

@ -140,7 +140,7 @@ find_methods (struct type *t, char *name, struct symbol **sym_arr)
method_name = dem_opname;
}
if (STREQ (name, method_name))
if (strcmp_iw (name, method_name) == 0)
/* Find all the overloaded methods with that name. */
for (field_counter = TYPE_FN_FIELDLIST_LENGTH (t, method_counter) - 1;
field_counter >= 0;

View file

@ -1,3 +1,8 @@
2001-03-21 Jim Blandy <jimb@redhat.com>
* gdb.c++/userdef.exp: Check that GDB tolerates whitespace in
unmangled operator names.
2001-03-20 Jim Blandy <jimb@redhat.com>
* gdb.threads/linux-dp.exp: Recognize an additional message

View file

@ -338,5 +338,9 @@ gdb_expect {
timeout { fail "(timeout) print value of two=one" }
}
# Check that GDB tolerates whitespace in operator names.
gdb_test "break A1::'operator+'" ".*Breakpoint $decimal at.*"
gdb_test "break A1::'operator +'" ".*Breakpoint $decimal at.*"
gdb_exit
return 0