* valops.c (value_struct_elt): Clarify error message.
gdb/testsuite/
2005-12-07  Christophe Lyon  <christophe.lyon@st.com>
	* gdb.cp/printmethod.cc (main): Call virt and nonvirt, to force
	code generation for these functions.
	* gdb.cp/printmethod.exp: Expect "&A::nonvirt()" instead of an
	error message.
This commit is contained in:
Daniel Jacobowitz
2005-12-07 23:07:54 +00:00
parent 7b6792f929
commit 55b3918466
5 changed files with 17 additions and 4 deletions

View File

@@ -1587,7 +1587,7 @@ value_struct_elt (struct value **argp, struct value **args,
v = search_struct_method (name, argp, args, 0, static_memfuncp, t);
if (v == (struct value *) - 1)
error (_("Cannot take address of a method"));
error (_("Cannot take address of method %s."), name);
else if (v == 0)
{
if (TYPE_NFN_FIELDS (t))