NEURON
hocstr.h
Go to the documentation of this file.
1 #ifndef hocstr_h
2 #define hocstr_h
3 #include <stdio.h>
4 /* too many time char* buf overruns its storage */
5 
6 
7 
8 typedef struct HocStr {
9  char* buf;
10  size_t size;
11 }HocStr;
12 
13 extern HocStr* hoc_tmpbuf; /* highly volatile, copy immediately */
14 extern HocStr* hocstr_create(size_t);
15 extern void hocstr_delete(HocStr*);
16 void hocstr_resize(HocStr*, size_t);
17 void hocstr_copy(HocStr*, const char*);
18 
19 
20 #endif
char * buf
Definition: hocstr.h:9
void hocstr_copy(HocStr *, const char *)
Definition: hoc.cpp:961
Definition: hocstr.h:8
HocStr * hoc_tmpbuf
Definition: hoc.cpp:164
size_t size
Definition: hocstr.h:10
HocStr * hocstr_create(size_t)
Definition: hoc.cpp:934
void hocstr_delete(HocStr *)
Definition: hoc.cpp:948
struct HocStr HocStr
void hocstr_resize(HocStr *, size_t)
Definition: hoc.cpp:953