dmake: do not set MAKEFLAGS=k
[unleashed/tickless.git] / usr / src / lib / krb5 / dyn / dyn.h
blobcbf4778c08944d3e4798af1c23ded10592d733e9
1 /*
2 * Copyright (c) 1997-2000 by Sun Microsystems, Inc.
3 * All rights reserved.
4 */
6 #ifndef _KRB5_DYN_DYN_H
7 #define _KRB5_DYN_DYN_H
9 #pragma ident "%Z%%M% %I% %E% SMI"
11 #ifdef __cplusplus
12 extern "C" {
13 #endif
17 * This file is part of libdyn.a, the C Dynamic Object library. It
18 * contains the public header file.
20 * There are no restrictions on this code; however, if you make any
21 * changes, I request that you document them so that I do not get
22 * credit or blame for your modifications.
24 * Written by Barr3y Jaspan, Student Information Processing Board (SIPB)
25 * and MIT-Project Athena, 1989.
30 * dyn.h -- header file to be included by programs linking against
31 * libdyn.a.
35 typedef char *DynPtr;
36 typedef struct _DynObject {
37 DynPtr array;
38 int el_size, num_el, size, inc;
39 int debug, paranoid, initzero;
40 } DynObjectRec, *DynObject;
42 /* Function macros */
43 #define DynHigh(obj) (DynSize(obj) - 1)
44 #define DynLow(obj) (0)
46 /* Return status codes */
47 #define DYN_OK -1000
48 #define DYN_NOMEM -1001
49 #define DYN_BADINDEX -1002
50 #define DYN_BADVALUE -1003
52 /* Function declarations */
53 #ifdef __STDC__
54 #define P(args) args
55 #else
56 #define P(args) ()
57 #endif /* __STDC__ */
59 DynObject DynCreate P((int el_size, int inc)), DynCopy P((DynObject obj));
60 int DynDestroy P((DynObject obj)), DynRelease P((DynObject obj));
61 int DynAdd P((DynObject obj, void *el));
62 int DynPut P((DynObject obj, void *el, int idx));
63 int DynInsert P((DynObject obj, int idx, void *els, int num));
64 int DynDelete P((DynObject obj, int idx));
65 DynPtr DynGet P((DynObject obj, int num));
66 DynPtr DynArray P((DynObject obj));
67 int DynDebug P((DynObject obj, int state));
68 int DynParanoid P((DynObject obj, int state));
69 int DynInitzero P((DynObject obj, int state));
70 int DynSize P((DynObject obj));
71 int DynCapacity P((DynObject obj));
73 #undef P
76 * N.B. The original code had the following comment line in it, after the last
77 * #endif:
78 * DO NOT ADD ANYTHING AFTER THIS #endif *
79 * This is in violatation of hdrchk standards, and so has been removed.
80 * If this causes any subsequent build problems, the build issues need
81 * to be resolved in a different fashion.
84 #ifdef __cplusplus
86 #endif
88 #endif /* !_KRB5_DYN_DYN_H */