gdb/testsuite: update field names in gdb-gdb.py.in
authorSimon Marchi <simon.marchi@polymtl.ca>
Fri, 23 Sep 2022 13:21:18 +0000 (09:21 -0400)
committerSimon Marchi <simon.marchi@polymtl.ca>
Mon, 26 Sep 2022 21:28:21 +0000 (17:28 -0400)
Patches that renamed the type::length and type::target_type fields
didn't update gdb-gdb.py.in accordingly, do that.

Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=29599
Change-Id: I0f3f37a94d43497789156b0ded4d2f2dd5b89496

gdb/gdb-gdb.py.in

index a6148d6dd67eea0c8cf56f52f6b0abc7881acddc..c43f54e202d3cb8228c7d1fab3cc7da3adba4cb3 100644 (file)
@@ -115,7 +115,7 @@ class StructTypePrettyPrinter:
         fields.append(
             "instance_flags = %s" % TypeFlagsPrinter(self.val["m_instance_flags"])
         )
-        fields.append("length = %d" % self.val["length"])
+        fields.append("length = %d" % self.val["m_length"])
         fields.append("main_type = %s" % self.val["main_type"])
         return "\n{" + ",\n ".join(fields) + "}"
 
@@ -260,7 +260,7 @@ class StructMainTypePrettyPrinter:
         fields.append("code = %s" % self.val["code"])
         fields.append("flags = [%s]" % self.flags_to_string())
         fields.append("owner = %s" % self.owner_to_string())
-        fields.append("target_type = %s" % self.val["target_type"])
+        fields.append("target_type = %s" % self.val["m_target_type"])
         if self.val["nfields"] > 0:
             for fieldno in range(self.val["nfields"]):
                 fields.append(self.struct_field_img(fieldno))