1 2/* This is a modified version of the file "arena.h" from 3 "C Interfaces and Implementations", by David R. Hanson. 4 The license is below. 5*/ 6/* 7 8The author of this software is David R. Hanson. 9 10Copyright (c) 1994,1995,1996,1997 by David R. Hanson. All Rights Reserved. 11 12Permission to use, copy, modify, and distribute this software for any 13purpose, subject to the provisions described below, without fee is 14hereby granted, provided that this entire notice is included in all 15copies of any software that is or includes a copy or modification of 16this software and in all copies of the supporting documentation for 17such software. 18 19THIS SOFTWARE IS BEING PROVIDED "AS IS", WITHOUT ANY EXPRESS OR IMPLIED 20WARRANTY. IN PARTICULAR, THE AUTHOR DOES MAKE ANY REPRESENTATION OR 21WARRANTY OF ANY KIND CONCERNING THE MERCHANTABILITY OF THIS SOFTWARE OR 22ITS FITNESS FOR ANY PARTICULAR PURPOSE. 23 24David Hanson / drh@microsoft.com / http://www.research.microsoft.com/~drh/ 25$Id: CPYRIGHT,v 1.2 1997/11/04 22:31:40 drh Exp $ 26*/ 27 28/* $Id: H:/drh/idioms/book/RCS/arena.doc,v 1.10 1997/02/21 19:45:19 drh Exp $ */ 29 30#ifndef _CII_ARENA_H 31#define _CII_ARENA_H 32 33//#include "except.h" 34#define T Arena_T 35typedef struct T *T; 36//extern const Except_T Arena_NewFailed; 37//extern const Except_T Arena_Failed; 38extern T Arena_new (void); 39extern void Arena_dispose(T *ap); 40extern void *Arena_alloc (T arena, long nbytes, 41 const char *file, int line); 42extern void *Arena_calloc(T arena, long count, 43 long nbytes, const char *file, int line); 44extern void Arena_free (T arena); 45#undef T 46 47#endif /* ndef _CII_ARENA_H */ 48