V25 with 64-bit support
[pforth] / csrc / pf_mem.h
CommitLineData
bb6b2dcd 1/* @(#) pf_mem.h 98/01/26 1.3 */\r
2#ifndef _pf_mem_h\r
3#define _pf_mem_h\r
4\r
5/***************************************************************\r
6** Include file for PForth Fake Memory Allocator\r
7**\r
8** Author: Phil Burk\r
9** Copyright 1994 3DO, Phil Burk, Larry Polansky, David Rosenboom\r
10**\r
11** The pForth software code is dedicated to the public domain,\r
12** and any third party may reproduce, distribute and modify\r
13** code is provided on an "as is" basis without any warranty\r
14** of any kind, including, without limitation, the implied\r
15** warranties of merchantability and fitness for a particular\r
16***************************************************************/\r
17\r
18#ifdef PF_NO_MALLOC\r
19\r
20 #ifdef __cplusplus\r
21 extern "C" {\r
22 #endif\r
23\r
24 void pfInitMemoryAllocator( void );\r
1cb310e6 25 char *pfAllocMem( cell_t NumBytes );\r
bb6b2dcd 26 void pfFreeMem( void *Mem );\r
27\r
28 #ifdef __cplusplus\r
29 } \r
30 #endif\r
31\r
32#else\r
33\r
34 #ifdef PF_USER_MALLOC\r
35/* Get user prototypes or macros from include file.\r
36** API must match that defined above for the stubs.\r
37*/\r
38 #include PF_USER_MALLOC\r
39 #else\r
40 #define pfInitMemoryAllocator()\r
41 #define pfAllocMem malloc\r
42 #define pfFreeMem free\r
43 #endif\r
44 \r
45#endif /* PF_NO_MALLOC */\r
46\r
47#endif /* _pf_mem_h */\r