The R Project SVN R-packages

Rev

Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
7747 ripley 1
#ifndef STRINGS_DEFS_HEADER
2
#define STRINGS_DEFS_HEADER
3
 
4
#include "../../../JSONOptions.h"
5
 
6
#ifdef JSON_UNICODE
7
    #define json_char wchar_t
8
    #define json_uchar wchar_t
9
    #ifdef __cplusplus
10
	   #include <cwchar>  /* need wide characters */
11
	   #ifndef JSON_STRING_HEADER
12
		  #include <string>
13
	   #endif
14
    #else
15
	   #include <wchar.h>  /* need wide characters */
16
    #endif
17
    #define JSON_TEXT(s) L ## s
18
    #define json_strlen wcslen
19
    #define json_strcmp wcscmp
20
#else
21
    #define json_char char
22
    #define json_uchar unsigned char
23
    #ifdef __cplusplus
24
	   #ifndef JSON_STRING_HEADER
25
		  #include <string>
26
	   #endif
27
    #else
28
	   #include <string.h> /* still need it for strlen and such */
29
    #endif
30
    #define JSON_TEXT(s) s
31
    #define json_strlen strlen
32
    #define json_strcmp strcmp
33
#endif
34
 
35
 
36
#endif