mirror of
https://github.com/espressif/binutils-gdb.git
synced 2025-08-06 06:45:56 +08:00
2011-08-26 Marc Khouzam <marc.khouzam@ericsson.com>
PR mi/11912 * varobj.c (cplus_describe_child): Add the keyword 'class' to the output of the method when dealing with a cast to a base class. 2011-08-26 Marc Khouzam <marc.khouzam@ericsson.com> PR mi/11912 * gdb.mi/mi-inheritance-syntax-error.cc: New file. * gdb.mi/mi-inheritance-syntax-error.exp: New file. * gdb.mi/mi-var-cp.cc: Updated for new 'class' keyword in output of -var-info-path-expression.
This commit is contained in:
10
gdb/varobj.c
10
gdb/varobj.c
@ -3443,8 +3443,14 @@ cplus_describe_child (struct varobj *parent, int index,
|
||||
will create an lvalue, for all appearences, so we don't
|
||||
need to use more fancy:
|
||||
*(Base1*)(&d)
|
||||
construct. */
|
||||
*cfull_expression = xstrprintf ("(%s(%s%s) %s)",
|
||||
construct.
|
||||
|
||||
When we are in the scope of the base class or of one
|
||||
of its children, the type field name will be interpreted
|
||||
as a constructor, if it exists. Therefore, we must
|
||||
indicate that the name is a class name by using the
|
||||
'class' keyword. See PR mi/11912 */
|
||||
*cfull_expression = xstrprintf ("(%s(class %s%s) %s)",
|
||||
ptr,
|
||||
TYPE_FIELD_NAME (type, index),
|
||||
ptr,
|
||||
|
Reference in New Issue
Block a user