… | |
… | |
391 | # define inline_speed static noinline |
391 | # define inline_speed static noinline |
392 | #else |
392 | #else |
393 | # define inline_speed static inline |
393 | # define inline_speed static inline |
394 | #endif |
394 | #endif |
395 | |
395 | |
396 | #define NUMPRI (EV_MAXPRI - EV_MINPRI + 1) |
396 | #define NUMPRI (EV_MAXPRI - EV_MINPRI + 1) |
|
|
397 | |
|
|
398 | #if EV_MINPRI == EV_MAXPRI |
|
|
399 | # define ABSPRI(w) (((W)w), 0) |
|
|
400 | #else |
397 | #define ABSPRI(w) (((W)w)->priority - EV_MINPRI) |
401 | # define ABSPRI(w) (((W)w)->priority - EV_MINPRI) |
|
|
402 | #endif |
398 | |
403 | |
399 | #define EMPTY /* required for microsofts broken pseudo-c compiler */ |
404 | #define EMPTY /* required for microsofts broken pseudo-c compiler */ |
400 | #define EMPTY2(a,b) /* used to suppress some warnings */ |
405 | #define EMPTY2(a,b) /* used to suppress some warnings */ |
401 | |
406 | |
402 | typedef ev_watcher *W; |
407 | typedef ev_watcher *W; |
… | |
… | |
2258 | } |
2263 | } |
2259 | |
2264 | |
2260 | inline_size void |
2265 | inline_size void |
2261 | pri_adjust (EV_P_ W w) |
2266 | pri_adjust (EV_P_ W w) |
2262 | { |
2267 | { |
2263 | int pri = w->priority; |
2268 | int pri = ev_priority (w); |
2264 | pri = pri < EV_MINPRI ? EV_MINPRI : pri; |
2269 | pri = pri < EV_MINPRI ? EV_MINPRI : pri; |
2265 | pri = pri > EV_MAXPRI ? EV_MAXPRI : pri; |
2270 | pri = pri > EV_MAXPRI ? EV_MAXPRI : pri; |
2266 | w->priority = pri; |
2271 | ev_set_priority (w, pri); |
2267 | } |
2272 | } |
2268 | |
2273 | |
2269 | inline_speed void |
2274 | inline_speed void |
2270 | ev_start (EV_P_ W w, int active) |
2275 | ev_start (EV_P_ W w, int active) |
2271 | { |
2276 | { |