)]}'
{
  "commit": "ef136c7fa165cf3ee75c37d41561be8a7bdc89bd",
  "tree": "1359a102119926582cb2b410123a790f1077cdde",
  "parents": [
    "b7a92724c5bd926e094ede860049c1067f0584cf"
  ],
  "author": {
    "name": "Tom de Vries",
    "email": "tdevries@suse.de",
    "time": "Thu Sep 07 21:39:42 2023 +0200"
  },
  "committer": {
    "name": "Tom de Vries",
    "email": "tdevries@suse.de",
    "time": "Thu Sep 07 21:39:42 2023 +0200"
  },
  "message": "[gdb/ada] Move identical enums handling later\n\nWhen running test-case gdb.ada/arr_acc_idx_w_gap.exp with target board\ncc-with-dwz, I run into:\n...\n(gdb) print enum_with_gaps\u0027enum_rep(lit3)^M\n\u0027Enum_Rep requires argument to have same type as enum^M\n(gdb) FAIL: gdb.ada/arr_acc_idx_w_gap.exp: enum_rep\n...\n\nWith target_board unix, we have instead:\n...\n(gdb) print enum_with_gaps\u0027enum_rep(lit3)^M\n$16 \u003d 13^M\n(gdb) PASS: gdb.ada/arr_acc_idx_w_gap.exp: enum_rep\n...\n\nConversely, when I add this test to the test-case:\n...\n     gdb_test \"print enum_with_gaps\u0027enum_rep(lit3)\" \" \u003d 13\" \\\n \t\"enum_rep\"\n+    gdb_test \"print enum_subrange\u0027enum_rep(lit3)\" \" \u003d 13\" \\\n+\t\"other enum_rep\"\n...\nthe extra test passes with target board cc-with-dwz, but fails with target\nboard unix.\n\nThe problem is here in remove_extra_symbols:\n...\n  if (symbols_are_identical_enums (syms))\n    syms.resize (1);\n...\nwhere one of the two identical enums is picked before the enum_rep handling\ncan resolve lit3 to one of the two.\n\nFix this by moving the code to ada_resolve_variable.\n\nTested on x86_64-linux.\n\nApproved-By: Tom Tromey \u003ctom@tromey.com\u003e\n\nPR ada/30726\nBug: https://sourceware.org/bugzilla/show_bug.cgi?id\u003d30726\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "c0cc512bfa31e2c378823d723b31c146d0698877",
      "old_mode": 33188,
      "old_path": "gdb/ada-lang.c",
      "new_id": "2e1b9664fdcba29ec0c16f5867e87e4966d9e0d4",
      "new_mode": 33188,
      "new_path": "gdb/ada-lang.c"
    },
    {
      "type": "modify",
      "old_id": "4a1482b6d995b72b03b4fea23a27064321c726be",
      "old_mode": 33188,
      "old_path": "gdb/testsuite/gdb.ada/arr_acc_idx_w_gap.exp",
      "new_id": "a98e9e1e2c363444ce5a80df64a40b963786e88c",
      "new_mode": 33188,
      "new_path": "gdb/testsuite/gdb.ada/arr_acc_idx_w_gap.exp"
    }
  ]
}
