public inbox for libabigail@sourceware.org
 help / color / mirror / Atom feed
From: Mark Wielaard <mark@klomp.org>
To: libabigail@sourceware.org
Cc: David Abdurachmanov <david.abdurachmanov@gmail.com>,
	Mark Wielaard <mark@klomp.org>
Subject: [PATCH 2/2] Fix ABG_ASSERT in build_ir_node_from_die for DW_TAG_member
Date: Fri, 29 Dec 2023 01:40:51 +0100	[thread overview]
Message-ID: <20231229004051.540340-3-mark@klomp.org> (raw)
In-Reply-To: <20231229004051.540340-1-mark@klomp.org>

When the die is a member, it is the CU of the die that should not be
in the C language, not the dwarf reader current translation unit.

	* src/abg-dwarf-reader.cc (build_ir_node_from_die): ABG_ASSERT
	!rdr.die_is_in_c(), not rdr.cur_transl_unit().

Signed-off-by: Mark Wielaard <mark@klomp.org>
---
 src/abg-dwarf-reader.cc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/abg-dwarf-reader.cc b/src/abg-dwarf-reader.cc
index 15a35edf..70e37403 100644
--- a/src/abg-dwarf-reader.cc
+++ b/src/abg-dwarf-reader.cc
@@ -15822,7 +15822,7 @@ build_ir_node_from_die(reader&	rdr,
 	bool var_is_cloned = false;
 
 	if (tag == DW_TAG_member)
-	  ABG_ASSERT(!is_c_language(rdr.cur_transl_unit()->get_language()));
+	  ABG_ASSERT(!rdr.die_is_in_c(die));
 
 	if (die_die_attribute(die, DW_AT_specification, spec_die, false)
 	    || (var_is_cloned = die_die_attribute(die, DW_AT_abstract_origin,
-- 
2.39.3


  parent reply	other threads:[~2023-12-29  0:41 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-12-29  0:40 Mark Wielaard
2023-12-29  0:40 ` [PATCH 1/2] Recognize EM_RISCV in e_machine_to_string Mark Wielaard
2023-12-29  0:40 ` Mark Wielaard [this message]
2024-01-08 15:13 ` none Dodji Seketeli
2024-01-08 19:14   ` Some libabigail RISC-V support issues Mark Wielaard

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20231229004051.540340-3-mark@klomp.org \
    --to=mark@klomp.org \
    --cc=david.abdurachmanov@gmail.com \
    --cc=libabigail@sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).