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/19510] the "private" keyword support has made -p1 output less useful


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

Josh Stone <jistone at redhat dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |jistone at redhat dot com

--- Comment #3 from Josh Stone <jistone at redhat dot com> ---
Both of these are due to not using semicolons.  Whitespace is not significant,
including newlines, so write it on one line to get an idea what the parser
sees.

> delete a b = "b"
> delete a (b) = ("b")

The latter looks like it's calling a(b).

> foo["hello"] = 0 ; ++ foo["hello"]
> (foo["hello"]) = (0) ++ (foo["hello"])

Note the former required a semicolon to parse as desired!
The latter is parsed like (0)++, then side-effect-free foo["hello"].


We probably should output semicolons after all statements to disambiguate
things, similar to how we wrap all expressions in parentheses.

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