Annotation of src/usr.bin/make/sprite.h, Revision 1.6
1.6 ! espie 1: /* $OpenBSD: sprite.h,v 1.5 1998/12/05 00:06:29 espie Exp $ */
1.3 millert 2: /* $NetBSD: sprite.h,v 1.6 1996/11/06 17:59:22 christos Exp $ */
1.1 deraadt 3:
4: /*
1.3 millert 5: * Copyright (c) 1988, 1989, 1990, 1993
6: * The Regents of the University of California. All rights reserved.
1.1 deraadt 7: * Copyright (c) 1989 by Berkeley Softworks
8: * All rights reserved.
9: *
10: * This code is derived from software contributed to Berkeley by
11: * Adam de Boor.
12: *
13: * Redistribution and use in source and binary forms, with or without
14: * modification, are permitted provided that the following conditions
15: * are met:
16: * 1. Redistributions of source code must retain the above copyright
17: * notice, this list of conditions and the following disclaimer.
18: * 2. Redistributions in binary form must reproduce the above copyright
19: * notice, this list of conditions and the following disclaimer in the
20: * documentation and/or other materials provided with the distribution.
21: * 3. All advertising materials mentioning features or use of this software
22: * must display the following acknowledgement:
23: * This product includes software developed by the University of
24: * California, Berkeley and its contributors.
25: * 4. Neither the name of the University nor the names of its contributors
26: * may be used to endorse or promote products derived from this software
27: * without specific prior written permission.
28: *
29: * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
30: * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
31: * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
32: * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
33: * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
34: * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
35: * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
36: * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
37: * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
38: * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
39: * SUCH DAMAGE.
40: *
1.3 millert 41: * from: @(#)sprite.h 8.1 (Berkeley) 6/6/93
1.1 deraadt 42: */
43:
44: /*
45: * sprite.h --
46: *
47: * Common constants and type declarations for Sprite.
48: */
49:
50: #ifndef _SPRITE
51: #define _SPRITE
52:
53:
54: /*
55: * A boolean type is defined as an integer, not an enum. This allows a
56: * boolean argument to be an expression that isn't strictly 0 or 1 valued.
57: */
58:
59: typedef int Boolean;
60: #ifndef TRUE
61: #define TRUE 1
1.4 mickey 62: #endif /* TRUE */
1.1 deraadt 63: #ifndef FALSE
64: #define FALSE 0
1.4 mickey 65: #endif /* FALSE */
1.1 deraadt 66:
67: /*
68: * Functions that must return a status can return a ReturnStatus to
69: * indicate success or type of failure.
70: */
71:
72: typedef int ReturnStatus;
73:
74: /*
1.3 millert 75: * The following statuses overlap with the first 2 generic statuses
1.1 deraadt 76: * defined in status.h:
77: *
78: * SUCCESS There was no error.
79: * FAILURE There was a general error.
80: */
81:
82: #define SUCCESS 0x00000000
83: #define FAILURE 0x00000001
84:
85:
86: #ifndef NULL
87: #define NULL 0
1.4 mickey 88: #endif /* NULL */
1.1 deraadt 89:
90: /*
91: * An address is just a pointer in C. It is defined as a character pointer
92: * so that address arithmetic will work properly, a byte at a time.
93: */
94:
95: typedef char *Address;
96:
97: /*
98: * ClientData is an uninterpreted word. It is defined as an int so that
99: * kdbx will not interpret client data as a string. Unlike an "Address",
100: * client data will generally not be used in arithmetic.
101: * But we don't have kdbx anymore so we define it as void (christos)
102: */
103:
104: typedef void *ClientData;
105:
106: #endif /* _SPRITE */