On Thu, Oct 17, 2024, at 1:00 PM, Mark Wielaard wrote:
> This part looks a little iffy IMHO.
> It feels like a layering violation.
> The meaning of DWFL_UNWOUND_INLINE is also different from the others.
> There is no worst/best ordering here.
> They are not connected to frames.
>
> Is there a way to move the printing of this into stack.c?
> For example make print_frame take a decorator argument that is a const
> char * instead of an unwound_source argument.

Ok, just to be clear that I understand what you want.

The unwound_source arguments (in print_frame+print_inline_frames)
changed to const char *. The print_frames() function
invokes unwound_source_str() to supply that argument.

struct frame still stores Dwfl_Unwound_Source, not char *.

In print_inline_frames the print_frame invocation is changed to
> print_frame (..., i > 1 ? "inline" : unwound_source)

DWFL_UNWOUND_INLINE removed from the enum,
making the enum a straightforward sequence of unwind methods.

I can do that.

Reply via email to