From: Mark Wooding Date: Sun, 23 Jun 2013 17:01:19 +0000 (+0100) Subject: yaid.h: Avoid the macro name `N'. X-Git-Tag: 1.0.1~3 X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~mdw/git/yaid/commitdiff_plain/1e00cfaa52ebc00219d8154721604bbc9ce3f1ad?ds=sidebyside yaid.h: Avoid the macro name `N'. Rename the helper macros of `RESPONSE' to `U_' and `N_'. --- diff --git a/yaid.h b/yaid.h index 18c17ec..ef3e726 100644 --- a/yaid.h +++ b/yaid.h @@ -195,12 +195,12 @@ extern void dputsock(dstr */*d*/, const struct addrops */*ao*/, enum { L, R, NDIR }; /* Response types, and the data needed to represent any associated data. A - * U(MEMB, TYPE) constructs a union member; an N means no associated data. + * U_(MEMB, TYPE) constructs a union member; an N_ means no associated data. */ #define RESPONSE(_) \ - _(ERROR, U(error, unsigned)) \ - _(UID, U(uid, uid_t)) \ - _(NAT, U(nat, struct socket)) + _(ERROR, U_(error, unsigned)) \ + _(UID, U_(uid, uid_t)) \ + _(NAT, U_(nat, struct socket)) enum { #define DEFENUM(what, branch) R_##what, @@ -234,11 +234,11 @@ struct query { unsigned resp; /* Our response type */ union { /* A union of response data */ #define DEFBRANCH(WHAT, branch) branch -#define U(memb, ty) ty memb; -#define N +#define U_(memb, ty) ty memb; +#define N_ RESPONSE(DEFBRANCH) -#undef U -#undef N +#undef U_ +#undef N_ #undef DEFBRANCH } u; } query;