5e856adbab3b1005c769913c2d61cd7b2e872e08
[nit.git] / c_src / string._nitni.h
1 #include <nit_common.h>
2 #include "standard___string._sep.h"
3 #ifndef STRING_NITNI_H
4 #define STRING_NITNI_H
5
6 #ifndef STRING_TYPE
7 #define STRING_TYPE
8 struct s_String{
9 struct nitni_ref ref; /* real ref struct, must be first */
10 };
11 typedef struct s_String *String;
12 #define String_incr_ref( x ) nitni_global_ref_incr( (struct nitni_ref*)(x) )
13 #define String_decr_ref( x ) nitni_global_ref_decr( (struct nitni_ref*)(x) )
14 #endif
15 #ifndef SYS_TYPE
16 #define SYS_TYPE
17 struct s_Sys{
18 struct nitni_ref ref; /* real ref struct, must be first */
19 };
20 typedef struct s_Sys *Sys;
21 #define Sys_incr_ref( x ) nitni_global_ref_incr( (struct nitni_ref*)(x) )
22 #define Sys_decr_ref( x ) nitni_global_ref_decr( (struct nitni_ref*)(x) )
23 #endif
24 #include "string_nit.h"
25
26 /* out/indirect function for string::String::to_f */
27 val_t String_to_f___out( val_t recv );
28
29 /* out/indirect function for string::Sys::native_argc */
30 val_t Sys_native_argc___out( val_t recv );
31
32 /* out/indirect function for string::Sys::native_argv */
33 val_t Sys_native_argv___out( val_t recv, val_t i );
34 #endif
35 /* friendly for string::String::to_cstring */
36 char * string_String_to_cstring( String recv );
37 #ifndef String_to_cstring
38 #define String_to_cstring string_String_to_cstring
39 #endif