File: alloc.h

package info (click to toggle)
anthy 6300d-2
  • links: PTS
  • area: main
  • in suites: sarge
  • size: 7,400 kB
  • ctags: 2,270
  • sloc: ansic: 17,009; sh: 13,554; lisp: 1,039; makefile: 252; ruby: 212; perl: 10
file content (43 lines) | stat: -rw-r--r-- 947 bytes parent folder | download | duplicates (7)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
/*
 * ¤allocator
 * Ǥatorά뤳Ȥ
 */
#ifndef _alloc_h_included_
#define _alloc_h_included_

/** Υϥɥ */
typedef struct allocator_priv * allocator;

/*
 * allocator
 * s: ¤Τsize(Хȿ)
 * dtor: =destructor ݤ֥ȤȤ˸ƤФؿ
 *  dtorΰϲ륪֥
 * ֤: allocator 
 */
allocator anthy_create_allocator(int s, void (*dtor)(void *));

/*
 * allocator
 *  κݤˡallocatorݤ줿֥ȤƲ
 * a: allocator
 */
void anthy_free_allocator(allocator a);

/*
 * ֥Ȥݤ
 * a: allocator
 * ֤: ݤ֥ȤΥɥ쥹
 */
void *anthy_smalloc(allocator a);
/*
 * ֥Ȥ
 * a: allocator
 * p: 륪֥ȤΥɥ쥹
 */
void anthy_sfree(allocator a, void *p);

/* Ƥallocator˴ */
void anthy_quit_allocator(void);

#endif