1: /* "@(#)cdefs.h 4.2 8/17/82" */
2: /* type modifiers */
3:
4: # define PTR 020
5: # define FTN 040
6: # define ARY 060
7:
8: /* type packing constants */
9:
10: # define TMASK 060
11: # define TMASK1 0300
12: # define TMASK2 0360
13: # define BTMASK 017
14: # define BTSHIFT 4
15: # define TSHIFT 2
16:
17: /* macros */
18:
19: # define BTYPE(x) (x&BTMASK) /* basic type of x */
20: # define ISUNSIGNED(x) ((x)<=ULONG&&(x)>=UCHAR)
21: # define UNSIGNABLE(x) ((x)<=LONG&&(x)>=CHAR)
22: # define ENUNSIGN(x) ((x)+(UNSIGNED-INT))
23: # define DEUNSIGN(x) ((x)+(INT-UNSIGNED))
24: # define ISPTR(x) ((x&TMASK)==PTR)
25: # define ISFTN(x) ((x&TMASK)==FTN) /* is x a function type */
26: # define ISARY(x) ((x&TMASK)==ARY) /* is x an array type */
27: # define INCREF(x) (((x&~BTMASK)<<TSHIFT)|PTR|(x&BTMASK))
28: # define DECREF(x) (((x>>TSHIFT)&~BTMASK&0x3fff)|(x&BTMASK))
29: /* pack and unpack field descriptors (size and offset) */
30: # define PKFIELD(s,o) ((o<<6)|s)
31: # define UPKFSZ(v) (v&077)
32: # define UPKFOFF(v) (v>>6)
Defined macros
ARY
defined in line
6; used 1 times
BTYPE
defined in line
19;
never used
FTN
defined in line
5; used 1 times
ISARY
defined in line
26; used 3 times
ISFTN
defined in line
25; used 2 times
ISPTR
defined in line
24; used 2 times
PTR
defined in line
4; used 2 times
TMASK
defined in line
10; used 5 times
Usage of this include