Pristine Ack-5.5
[Ack-5.5.git] / lang / cem / lint / lpass2 / class.h
1 /*
2  * (c) copyright 1987 by the Vrije Universiteit, Amsterdam, The Netherlands.
3  * See the copyright notice in the ACK home directory, in the file "Copyright".
4  */
5 /* $Id: class.h,v 1.5 1994/06/24 12:25:33 ceriel Exp $ */
6
7 /*      Bit patterns to allow fast answers to set questions about classes.
8         The classes in the inpdef are given as single letters; the array
9         class[] contains a bit pattern for each letter, with those bits set
10         that correspond to the lint class meaning of the letter.
11
12         This facility is used through the macro  is_class(inpdef_var, CL_XXX)
13 */
14
15 #define CL_DEF          (1<<0)
16 #define CL_DECL         (1<<1)
17 #define CL_USAGE        (1<<2)
18
19 #define CL_FUNC         (1<<3)
20 #define CL_VAR          (1<<4)
21
22 #define CL_LIB          (1<<5)
23 #define CL_EXT          (1<<6)
24 #define CL_IMPL         (1<<7)
25 #define CL_STAT         (1<<8)
26
27 extern int class[];
28
29 #define is_class(id,cl) ((class[(id)->id_class-MIN_CLASS_CONST] & (cl)) == (cl))
30