public inbox for systemtap@sourceware.org
 help / color / mirror / Atom feed
* [Bug translator/11004] New: error catching syntax
@ 2009-11-23 18:28 fche at redhat dot com
  2010-01-18 20:17 ` [Bug translator/11004] " fche at redhat dot com
  2010-03-01 18:29 ` fche at redhat dot com
  0 siblings, 2 replies; 3+ messages in thread
From: fche at redhat dot com @ 2009-11-23 18:28 UTC (permalink / raw)
  To: systemtap

We need something more fine than --skip-badvars to tolerate
run-time errors associated with $expression evaluation.
Something like this:

try {
   stmt1 ... 
} catch (varname) {
   stmt2 ...
}

semantics being: optional "varname" would get assigned the error
string, and stmt2 would be evaluated, should the stmt1 block be
departed due to an error (that sets context->last_error).

This would be used for $variable protection thusly:

for (i=0; i<100; i++) {
  try {
    println("%d", $var->field[i])
  } catch {
    println("oops")
    # don't break to continue iteration; or break to leave early
  }
}

-- 
           Summary: error catching syntax
           Product: systemtap
           Version: unspecified
            Status: NEW
          Severity: normal
          Priority: P2
         Component: translator
        AssignedTo: systemtap at sources dot redhat dot com
        ReportedBy: fche at redhat dot com


http://sourceware.org/bugzilla/show_bug.cgi?id=11004

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

^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Bug translator/11004] error catching syntax
  2009-11-23 18:28 [Bug translator/11004] New: error catching syntax fche at redhat dot com
@ 2010-01-18 20:17 ` fche at redhat dot com
  2010-03-01 18:29 ` fche at redhat dot com
  1 sibling, 0 replies; 3+ messages in thread
From: fche at redhat dot com @ 2010-01-18 20:17 UTC (permalink / raw)
  To: systemtap



-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
OtherBugsDependingO|                            |11179
              nThis|                            |


http://sourceware.org/bugzilla/show_bug.cgi?id=11004

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

^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Bug translator/11004] error catching syntax
  2009-11-23 18:28 [Bug translator/11004] New: error catching syntax fche at redhat dot com
  2010-01-18 20:17 ` [Bug translator/11004] " fche at redhat dot com
@ 2010-03-01 18:29 ` fche at redhat dot com
  1 sibling, 0 replies; 3+ messages in thread
From: fche at redhat dot com @ 2010-03-01 18:29 UTC (permalink / raw)
  To: systemtap



-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
         AssignedTo|systemtap at sources dot    |fche at redhat dot com
                   |redhat dot com              |
             Status|NEW                         |ASSIGNED


http://sourceware.org/bugzilla/show_bug.cgi?id=11004

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

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2010-03-01 18:29 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-11-23 18:28 [Bug translator/11004] New: error catching syntax fche at redhat dot com
2010-01-18 20:17 ` [Bug translator/11004] " fche at redhat dot com
2010-03-01 18:29 ` fche at redhat dot com

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).