This is the mail archive of the binutils@sources.redhat.com mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] nm size/value output fixes.


Hi Elias,

> Of course, there are more to be done. I would like to have a code
> review from the maintainers, in order to proceed and change the
> other formats, too, which, using my patch, are misfunctional.

The patch is looking good.

One thing I would suggest is to add macros to access the fields in the
symbol_info and extended_symbol_info structures, eg:

#define SYM_VALUE(sym)  (sym->sinfo->value)
#define SYM_SIZE(sym)   (sym->ssize)

and then use them throughout the code.  That way if you do have to
change the layout of the structures (eg because you find you have to
move the ssize field into the _symbol_info struct) then you only have
to change the accessor macro and not tons of lines of code.

Cheers
        Nick


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]