Switch to the OpenBSD implementations of the wide scanf functions.
This also gets us the C99 wcstoimax and wcstoumax, and a working fgetwc and ungetwc, all of which are needed in the implementation. This also brings several other files closer to upstream. Change-Id: I23b025a8237a6dbb9aa50d2a96765ea729a85579
This commit is contained in:
@@ -38,3 +38,11 @@ TEST(inttypes, misc) {
|
||||
sscanf(buf, "%08" SCNuPTR, &u);
|
||||
sscanf(buf, "%08" SCNxPTR, &u);
|
||||
}
|
||||
|
||||
TEST(inttypes, wcstoimax) {
|
||||
ASSERT_EQ(123, wcstoimax(L"123", NULL, 10));
|
||||
}
|
||||
|
||||
TEST(inttypes, wcstoumax) {
|
||||
ASSERT_EQ(123U, wcstoumax(L"123", NULL, 10));
|
||||
}
|
||||
|
Reference in New Issue
Block a user