[PATCH][objdump] UTF-8 jump visuzalization

Jan Beulich jbeulich@suse.com
Wed Jul 3 14:49:31 GMT 2024


On 29.06.2024 18:38, Jiří Wolker wrote:
> I finally returned to the patch for use of box-drawing characters in the 
> objdump. I attach a patch that has few bugs from the work-in-progress 
> patch fixed and also contains documentation changes.

Yet it doesn't address the command line option related remark of mine.

In the OBJDUMP_JUMP_LINES doc the example contains a use of "arrow",
yet there's no such key in the subsequent enumeration.

I further think that "hor" and "ver" are too much abbreviated. May I
suggest at least "horiz" and "vert"?

I think to contrast it from ASCII, the doc piece also wants to explicitly
say e.g. "unicode box drawing characters". Iirc some of the extended-
ASCII code pages had a few box drawing characters, too. You probably also
want to mention that the mere presence of the (non-empty) env var
switches objdump into UTF-8 mode, as if the new command line option was
given, but irrespective of its contents actually being recognized.

I also wonder whether you using "lines" as the term in various places is
going to be / remain sufficiently unambiguous. Did you consider using the
term "box" instead?

As to your use of getenv(): You may not alter the space pointed to by its
return value. You also shouldn't retain pointers into that area, as it
may be overwritten by a later call to getenv().

Finally, going forward, would it be possible that you arrange for sending
patches inline rather than (or in addition to) as attachment? This eases
commenting on particular aspects. Just to give an example: I don't really
see why jump_line_env_tokens[] needs a sentinel NULL. That would be
easier to ask with proper context in place.

Jan


More information about the Binutils mailing list