This is the mail archive of the systemtap@sourceware.org mailing list for the systemtap 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]

[Bug translator/16165] @perf operator in error msgs is corrupted


https://sourceware.org/bugzilla/show_bug.cgi?id=16165

--- Comment #3 from Jonathan Lebon <jlebon at redhat dot com> ---
This is due to the @perf operator getting expanded to the counter symbol (see
dwarf_var_expanding_visitor::visit_perf_op()). The issue is that the symbol's
token content is set to the literal value passed to the @perf operator.

What then happens is that when we try to color the offending token, the token's
content ('a') doesn't match the original source line ('@perf').

There are (at least) two possible ways to fix this:
Patch 1. Only color stuff whose contents would match exactly the source line.
Patch 2. Make sure the new token the expanded perf symbol uses has the original
content.

Not sure what's the right way. Patch 1 is more general in that other things of
this sort will not be colored. On the other hand, patch 2 allows the '@perf'
keyword to get colored, but I'm not entirely sure what other repercussions
replacing the content may have (and whether this is something done in other
places).

-- 
You are receiving this mail because:
You are the assignee for the bug.


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