Fix icu4c calling on x86.
Some of the function pointer types were wrong, and x86 cares if you
say `int` when you meant `int8_t` (because it feels at liberty to
leave the top bits dirty and ignore them, both sides need to agree
which they're dealing with).
Also slightly improve the wcstoimax and wcstoumax tests, since my
investigation started there.
Bug: http://b/33451822
Test: tests pass on x86, arm, and arm64
Change-Id: I553193962f0cb993666f9f8e415990bba5b669e1
diff --git a/libc/private/icu.h b/libc/private/icu.h
index c5d89b8..03fdf66 100644
--- a/libc/private/icu.h
+++ b/libc/private/icu.h
@@ -29,6 +29,27 @@
#ifndef _PRIVATE_ICU_H
#define _PRIVATE_ICU_H
+#include <stdint.h>
+
+typedef int8_t UBool;
+typedef int32_t UChar32;
+
+enum UProperty {
+ UCHAR_ALPHABETIC = 0,
+ UCHAR_LOWERCASE = 22,
+ UCHAR_POSIX_ALNUM = 44,
+ UCHAR_POSIX_BLANK = 45,
+ UCHAR_POSIX_GRAPH = 46,
+ UCHAR_POSIX_PRINT = 47,
+ UCHAR_POSIX_XDIGIT = 48,
+ UCHAR_UPPERCASE = 30,
+ UCHAR_WHITE_SPACE = 31,
+};
+
+enum UCharCategory {
+ U_CONTROL_CHAR = 15,
+};
+
void* __find_icu_symbol(const char* symbol_name);
#endif // _PRIVATE_ICU_H