cc/cpp/tests/test10
raw| 1 | #define __CONCAT(x,y) x ## y |
| 2 | #define dev_type_open(n) int n(int) |
| 3 | #define dev_decl(n,t) __CONCAT(dev_type_,t)(__CONCAT(n,t)) |
| 4 | #define cdev_decl(n) dev_decl(n,open) |
| 5 | |
| 6 | cdev_decl(midi); |
| 7 | |
| 8 | # define __GETOPT_PREFIX foo_ |
| 9 | # define __GETOPT_CONCAT(x, y) x ## y |
| 10 | # define __GETOPT_XCONCAT(x, y) __GETOPT_CONCAT (x, y) |
| 11 | # define __GETOPT_ID(y) __GETOPT_XCONCAT (__GETOPT_PREFIX, y) |
| 12 | # define optarg __GETOPT_ID (optarg) |
| 13 | |
| 14 | optarg |