This is the mail archive of the
mailing list for the binutils project.
make bfd_target symbol_leading_char variable?
- To: binutils at sources dot redhat dot com
- Subject: make bfd_target symbol_leading_char variable?
- From: Hans-Peter Nilsson <hp at axis dot com>
- Date: Thu, 7 Sep 2000 16:26:26 +0200
I'd like to be able to have the value of
bfd_get_symbol_leading_char non-fixed for a target, decided by
(primarily) object file flags.
What controls this (outside of gas) is
in the bfd_target structure. But it isn't modifiable, since in
a struct _bfd, the xvec member is
const struct bfd_target *xvec;
It would be wrong to make xvec non-const, but perhaps we can
change "char symbol_leading_char" into "char
*symbol_leading_char_p", where the character pointed to is
supposed to be changeable for some time at least up to after
*_bfd_copy_private_bfd_data or *_bfd_merge_private_bfd_data? I
believe a minimal number of callers need to be changed (object
format files, targets.c and bfd-in.h), and the runtime penalty
should be unnoticable.
Is this a change that stand a chance to be approved?
Another approach could be to make a different bfd_target with
only a different symbol_leading_char. No other targets would be
affected. But I think it would be, um, less clean, and I'm not
really sure it is a realistic change.