34 |
// TODO: Test extractions for PartialMatch/Consume |
// TODO: Test extractions for PartialMatch/Consume |
35 |
|
|
36 |
#ifdef HAVE_CONFIG_H |
#ifdef HAVE_CONFIG_H |
37 |
#include <config.h> |
#include "config.h" |
38 |
#endif |
#endif |
39 |
|
|
40 |
#ifdef _WIN32 |
#ifdef HAVE_WINDOWS_H |
41 |
#define snprintf _snprintf |
#define snprintf _snprintf |
42 |
#endif |
#endif |
43 |
|
|
1136 |
printf("Testing UTF-8 handling\n"); |
printf("Testing UTF-8 handling\n"); |
1137 |
|
|
1138 |
// Three Japanese characters (nihongo) |
// Three Japanese characters (nihongo) |
1139 |
const char utf8_string[] = { |
const unsigned char utf8_string[] = { |
1140 |
0xe6, 0x97, 0xa5, // 65e5 |
0xe6, 0x97, 0xa5, // 65e5 |
1141 |
0xe6, 0x9c, 0xac, // 627c |
0xe6, 0x9c, 0xac, // 627c |
1142 |
0xe8, 0xaa, 0x9e, // 8a9e |
0xe8, 0xaa, 0x9e, // 8a9e |
1143 |
0 |
0 |
1144 |
}; |
}; |
1145 |
const char utf8_pattern[] = { |
const unsigned char utf8_pattern[] = { |
1146 |
'.', |
'.', |
1147 |
0xe6, 0x9c, 0xac, // 627c |
0xe6, 0x9c, 0xac, // 627c |
1148 |
'.', |
'.', |