When printing a value, I think the history reference -- the "$1" in
the output -- should be styled using the "variable" style. This patch
implements this.
annotate_value_history_begin (histindex, val->type ());
- gdb_printf ("$%d = ", histindex);
+ std::string idx = string_printf ("$%d", histindex);
+ gdb_printf ("%ps = ", styled_string (variable_name_style.style (),
+ idx.c_str ()));
annotate_value_history_value ();
set sfield [limited_style string_field variable]
set efield [limited_style e_field variable]
set evalue [limited_style VALUE_TWO variable]
+ set lhs [limited_style "\\\$$decimal" variable]
gdb_test "print struct_value" \
- "\{$ifield = 23,.*$sfield = .*,.*$efield = $evalue.*"
+ "$lhs = \{$ifield = 23,.*$sfield = .*,.*$efield = $evalue.*"
set ffield [limited_style field variable]
set cstart [string_to_regexp "/* XXX "]