futriix-old/src/storage.h
John Sully f243e3cc33 Support configurable file backed scratch
Former-commit-id: bbcaf48cb0ddb7945e13456e13e139fe5eaa3dff
2019-02-01 13:54:59 -05:00

20 lines
427 B
C

#ifndef __STORAGE_H__
#define __STORAGE_H__
#define OBJ_ENCODING_EMBSTR_SIZE_LIMIT 44 // Note: also defined in object.c - should always match
enum MALLOC_CLASS
{
MALLOC_LOCAL,
MALLOC_SHARED,
};
void storage_init(const char *tmpfilePath);
void *salloc(size_t cb, enum MALLOC_CLASS class);
void *scalloc(size_t cb, size_t c, enum MALLOC_CLASS class);
void sfree(void*);
void *srealloc(void *pv, size_t cb);
#endif