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/14924] warn on complex $ptr->foo expressions in .return probes


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

--- Comment #10 from Martin Cermak <mcermak at redhat dot com> ---
Created attachment 9630
  --> https://sourceware.org/bugzilla/attachment.cgi?id=9630&action=edit
possible patch

First round of full testing and fixes.  ITSM there is now a slight syntactical
issue with @defined in return probes:  What was earlier easily expressible like
e.g. this:

=======
        if (@defined($s)) {
                bytes_req = $s->size
                ...
        }
        else
        ...
=======

does now probably need following handling:

=======
        if (@entry(@defined($s))) {
                bytes_req = @entry(@choose_defined($s->size, 0))
                ...
        }
        else
        ...
=======

I'm not sure I like this, because it's not syntactically terse enough, and it
requires a "default" value which possibly can cause collisions.  Thoughts?

-- 
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]