diff --git a/gdb/testsuite/gdb.cp/psymtab-parameter.cc b/gdb/testsuite/gdb.cp/psymtab-parameter.cc
index 9f63fefcaeb800f7444fe74225514d3330036e5b..63038f03237b64ce4bff88e42fee7f836eca3249 100644
--- a/gdb/testsuite/gdb.cp/psymtab-parameter.cc
+++ b/gdb/testsuite/gdb.cp/psymtab-parameter.cc
@@ -16,9 +16,10 @@
along with this program. If not, see . */
template
-void
+long
func ()
{
+ return 0L;
}
void
diff --git a/gdb/testsuite/gdb.cp/psymtab-parameter.exp b/gdb/testsuite/gdb.cp/psymtab-parameter.exp
index 5c4b6ac71927fe9030bd9ce66111761425ab433b..3d78de91f4b3752d754bd776ae3532700a308a40 100644
--- a/gdb/testsuite/gdb.cp/psymtab-parameter.exp
+++ b/gdb/testsuite/gdb.cp/psymtab-parameter.exp
@@ -31,6 +31,6 @@ gdb_test_no_output "set language c++"
# XFAIL than FAIL here. For example -readnow breaks it.
gdb_test_no_output "maintenance info symtabs"
-# GDB has shown only the `void func()' ELF symbol before, not the DWARF
+# GDB has shown only the `long func()' ELF symbol before, not the DWARF
# symbol
gdb_test "complete p 'func(" "p 'func\\(\\)"