public inbox for systemtap@sourceware.org
 help / color / mirror / Atom feed
* [Bug tapsets/18876] New: need to assert
@ 2015-08-26 20:28 fche at redhat dot com
  2015-11-23 20:44 ` [Bug tapsets/18876] " fche at redhat dot com
  0 siblings, 1 reply; 2+ messages in thread
From: fche at redhat dot com @ 2015-08-26 20:28 UTC (permalink / raw)
  To: systemtap

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

            Bug ID: 18876
           Summary: need to assert
           Product: systemtap
           Version: unspecified
            Status: NEW
          Severity: normal
          Priority: P2
         Component: tapsets
          Assignee: systemtap at sourceware dot org
          Reporter: fche at redhat dot com
  Target Milestone: ---

We have several bits of code in the tapset (and perhaps also in the
samples) looking like this:

   if (condition) {
      error("foo")
      return 0
   }

(Note first that any statements after an error() call are already
dead.)

Let's have a new tapset function like assert(), so all that type of
code can look like this instead:

   assert(condition, "foo")

It could be implemented simply as:

   function assert(cond,msg) { if (!cond) error(msg) }

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

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

* [Bug tapsets/18876] need to assert
  2015-08-26 20:28 [Bug tapsets/18876] New: need to assert fche at redhat dot com
@ 2015-11-23 20:44 ` fche at redhat dot com
  0 siblings, 0 replies; 2+ messages in thread
From: fche at redhat dot com @ 2015-11-23 20:44 UTC (permalink / raw)
  To: systemtap

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

Frank Ch. Eigler <fche at redhat dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|---                         |FIXED

--- Comment #1 from Frank Ch. Eigler <fche at redhat dot com> ---
commit 34830c36 etc.

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

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

end of thread, other threads:[~2015-11-23 20:44 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-08-26 20:28 [Bug tapsets/18876] New: need to assert fche at redhat dot com
2015-11-23 20:44 ` [Bug tapsets/18876] " 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).