aboutsummaryrefslogtreecommitdiff
path: root/tests/core/test_wprintf.c
diff options
context:
space:
mode:
authorAlon Zakai <alonzakai@gmail.com>2014-01-13 16:44:17 -0800
committerAlon Zakai <alonzakai@gmail.com>2014-01-13 17:03:24 -0800
commit0e36f078d4a9666303340506638726d316096e07 (patch)
tree173987ffb4995f03b518825885531fc1e6b2e9d0 /tests/core/test_wprintf.c
parentcd1edebb5034ea52396a5b68304e84ae80878740 (diff)
add fputwc, which enables wprintf1.8.9
Diffstat (limited to 'tests/core/test_wprintf.c')
-rw-r--r--tests/core/test_wprintf.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/tests/core/test_wprintf.c b/tests/core/test_wprintf.c
new file mode 100644
index 00000000..e938bf69
--- /dev/null
+++ b/tests/core/test_wprintf.c
@@ -0,0 +1,15 @@
+#include <wchar.h>
+
+int main()
+{
+ wprintf (L"Characters: %lc %lc \n", L'a', 65);
+ wprintf (L"Decimals: %d %ld\n", 1977, 650000L);
+ wprintf (L"Preceding with blanks: %10d \n", 1977);
+ wprintf (L"Preceding with zeros: %010d \n", 1977);
+ wprintf (L"Some different radixes: %d %x %o %#x %#o \n", 100, 100, 100, 100, 100);
+ wprintf (L"floats: %4.2f %+.0e %E \n", 3.1416, 3.1416, 3.1416);
+ wprintf (L"Width trick: %*d \n", 5, 10);
+ wprintf (L"%ls \n", L"A wide string");
+ return 0;
+}
+