aboutsummaryrefslogtreecommitdiff
path: root/libctf
diff options
context:
space:
mode:
authorNick Alcock <nick.alcock@oracle.com>2025-04-25 21:22:34 +0100
committerNick Alcock <nick.alcock@oracle.com>2025-04-25 21:23:08 +0100
commit1ec572d423672c5fa9f2d214c4dee81f26b4d1dc (patch)
treef16d6f858f9ef50306aaa516a448dea65dcb3af8 /libctf
parent8586d4d1fd6b405831bc4b95c658f596a17b00cf (diff)
downloadbinutils-1ec572d423672c5fa9f2d214c4dee81f26b4d1dc.zip
binutils-1ec572d423672c5fa9f2d214c4dee81f26b4d1dc.tar.gz
binutils-1ec572d423672c5fa9f2d214c4dee81f26b4d1dc.tar.bz2
libctf: dump: dump conflicting CUs, when declared
Diffstat (limited to 'libctf')
-rw-r--r--libctf/ctf-dump.c14
1 files changed, 13 insertions, 1 deletions
diff --git a/libctf/ctf-dump.c b/libctf/ctf-dump.c
index f76dec9..2362cb7 100644
--- a/libctf/ctf-dump.c
+++ b/libctf/ctf-dump.c
@@ -206,7 +206,19 @@ ctf_dump_format_type (ctf_dict_t *fp, ctf_id_t id, int flag)
}
if (nonroot_trailer[0] != 0)
- str = str_append (str, nonroot_trailer);
+ {
+ int conflicting;
+ const char *conflicting_cu;
+
+ if ((conflicting = ctf_type_conflicting (fp, id, &conflicting_cu)) < 0)
+ goto oom;
+ if (conflicting && conflicting_cu[0] != 0)
+ {
+ str = str_append (str, ": conflicting in ");
+ str = str_append (str, conflicting_cu);
+ }
+ str = str_append (str, nonroot_trailer);
+ }
/* Just exit after one iteration if we are not showing the types this type
references. */