summaryrefslogtreecommitdiff
path: root/ev.h
diff options
context:
space:
mode:
authorroot <root>2009-10-20 00:50:31 +0000
committerroot <root>2009-10-20 00:50:31 +0000
commit7d870240875a77fe99b67dd48318fef34f23fc27 (patch)
tree160b8183b1d816a78e238f4ea56b59d35a13360b /ev.h
parent4939ae0708bd57123dcd1f5687d288a222231e20 (diff)
*** empty log message ***
Diffstat (limited to 'ev.h')
-rw-r--r--ev.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/ev.h b/ev.h
index 372e895..e6af59a 100644
--- a/ev.h
+++ b/ev.h
@@ -365,7 +365,7 @@ typedef struct ev_async
EV_ATOMIC_T sent; /* private */
} ev_async;
-# define ev_async_pending(w) ((w)->sent + 0)
+# define ev_async_pending(w) (+(w)->sent)
#endif
/* the presence of this union forces similar struct layout */
@@ -613,11 +613,11 @@ void ev_resume (EV_P);
# define ev_priority(ev) ((ev), EV_MINPRI)
# define ev_set_priority(ev,pri) ((ev), (pri))
#else
-# define ev_priority(ev) ((((ev_watcher *)(void *)(ev))->priority) + 0)
+# define ev_priority(ev) (+(((ev_watcher *)(void *)(ev))->priority))
# define ev_set_priority(ev,pri) ( (ev_watcher *)(void *)(ev))->priority = (pri)
#endif
-#define ev_periodic_at(ev) (((ev_watcher_time *)(ev))->at + 0.)
+#define ev_periodic_at(ev) (+((ev_watcher_time *)(ev))->at)
#ifndef ev_set_cb
# define ev_set_cb(ev,cb_) ev_cb (ev) = (cb_)