• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 #include <poll.h>
2 #define T(t) (t*)0;
3 #define F(t,n) {t *y = &x.n;}
4 #define C(n) switch(n){case n:;}
f()5 static void f()
6 {
7 T(nfds_t)
8 {
9 struct pollfd x;
10 F(int, fd)
11 F(short, events)
12 F(short, revents)
13 }
14 C(POLLIN)
15 C(POLLRDNORM)
16 C(POLLRDBAND)
17 C(POLLPRI)
18 C(POLLOUT)
19 C(POLLWRNORM)
20 C(POLLWRBAND)
21 C(POLLERR)
22 C(POLLHUP)
23 C(POLLNVAL)
24 {int(*p)(struct pollfd[],nfds_t,int) = poll;}
25 }
26