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