aboutsummaryrefslogtreecommitdiff
path: root/gdb/testsuite
diff options
context:
space:
mode:
authorDavid Carlton <carlton@bactrian.org>2003-04-23 23:45:24 +0000
committerDavid Carlton <carlton@bactrian.org>2003-04-23 23:45:24 +0000
commit0f20eeea6ca163e7ccd59182814406dcef5fe7bb (patch)
tree20eb983a62572e57761b146bac0c41b6cc6da8a0 /gdb/testsuite
parent74cfe982eda9d4293f25e0b94355f721321ba47e (diff)
downloadgdb-0f20eeea6ca163e7ccd59182814406dcef5fe7bb.zip
gdb-0f20eeea6ca163e7ccd59182814406dcef5fe7bb.tar.gz
gdb-0f20eeea6ca163e7ccd59182814406dcef5fe7bb.tar.bz2
2003-04-23 David Carlton <carlton@bactrian.org>
* cp-support.c (cp_find_first_component): Accept 'operator' in more locations. 2003-04-23 David Carlton <carlton@bactrian.org> * gdb.c++/maint.exp (test_first_component): Add tests for 'operator' in more locations.
Diffstat (limited to 'gdb/testsuite')
-rw-r--r--gdb/testsuite/ChangeLog5
-rw-r--r--gdb/testsuite/gdb.c++/maint.exp12
2 files changed, 17 insertions, 0 deletions
diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog
index 7ace150..96b2838 100644
--- a/gdb/testsuite/ChangeLog
+++ b/gdb/testsuite/ChangeLog
@@ -1,3 +1,8 @@
+2003-04-23 David Carlton <carlton@bactrian.org>
+
+ * gdb.c++/maint.exp (test_first_component): Add tests for
+ 'operator' in more locations.
+
2003-04-16 Kevin Buettner <kevinb@redhat.com>
* gdb.base/args.exp: Invoke gdb_load for simulator targets.
diff --git a/gdb/testsuite/gdb.c++/maint.exp b/gdb/testsuite/gdb.c++/maint.exp
index 6e1da97..a0f15f9 100644
--- a/gdb/testsuite/gdb.c++/maint.exp
+++ b/gdb/testsuite/gdb.c++/maint.exp
@@ -63,6 +63,18 @@ proc test_first_component {} {
test_single_component "foo(std::basic_streambuf<wchar_t,std::char_traits<wchar_t> >)"
test_single_component "operator>(X::Y)"
+ # Operator names can show up in weird places.
+
+ test_single_component "int operator<< <char>()"
+ test_single_component "T<Cooperator>"
+
+ # NOTE: carlton/2003-04-23: I've only seen the first of these
+ # produced by the demangler, but I'm including two more just to be
+ # on the safe side.
+ test_single_component "int foo<&(operator<<(C, C))>()"
+ test_single_component "int foo<&operator<<(C, C)>()"
+ test_single_component "int foo<operator<<(C, C)>()"
+
gdb_test "maint cp first_component foo::bar" "foo"
gdb_test "maint cp first_component foo::bar::baz" "foo"
gdb_test "maint cp first_component C<A>::bar" "C<A>"