xref: /original-bsd/bin/test/operators.h (revision 7e5c8007)
1 /*-
2  * Copyright (c) 1993, 1994
3  *	The Regents of the University of California.  All rights reserved.
4  *
5  * %sccs.include.redist.c%
6  *
7  *	@(#)operators.h	8.3 (Berkeley) 04/02/94
8  */
9 
10 #define	NOT		0
11 #define	ISBLOCK		1
12 #define	ISCHAR		2
13 #define	ISDIR		3
14 #define	ISEXIST		4
15 #define	ISFILE		5
16 #define	ISSETGID	6
17 #define	ISSYMLINK	7
18 #define	ISSTICKY	8
19 #define	STRLEN		9
20 #define	ISFIFO		10
21 #define	ISREAD		11
22 #define	ISSIZE		12
23 #define	ISTTY		13
24 #define	ISSETUID	14
25 #define	ISWRITE		15
26 #define	ISEXEC		16
27 #define	NULSTR		17
28 
29 #define	FIRST_BINARY_OP	18
30 #define	OR1		18
31 #define	OR2		19
32 #define	AND1		20
33 #define	AND2		21
34 #define	STREQ		22
35 #define	STRNE		23
36 #define	EQ		24
37 #define	NE		25
38 #define	GT		26
39 #define	LT		27
40 #define	LE		28
41 #define	GE		29
42 
43 
44 #define	OP_INT		1	/* arguments to operator are integer */
45 #define	OP_STRING	2	/* arguments to operator are string */
46 #define	OP_FILE		3	/* argument is a file name */
47 
48 extern const char *const unary_op[];
49 extern const char *const binary_op[];
50 extern const char op_priority[];
51 extern const char op_argflag[];
52