From ee3f67bfd08763701deaec40f98c01786d94817a Mon Sep 17 00:00:00 2001 From: Sven Gothel Date: Sat, 3 Sep 2022 04:59:01 +0200 Subject: test_basictypeconv.cpp: Fix int format for 32bit compilation --- test/test_basictypeconv.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'test/test_basictypeconv.cpp') diff --git a/test/test_basictypeconv.cpp b/test/test_basictypeconv.cpp index 1dab771..f2b7749 100644 --- a/test/test_basictypeconv.cpp +++ b/test/test_basictypeconv.cpp @@ -393,15 +393,15 @@ static void testRadix32(const int base) { // UTF-8 (or codepage 437) <-> ASCII collision const std::string s1 = "Ç"; const std::string s2 = "é"; - fprintf(stderr, "test.s1 '%s' %03d, %03d, size %zu\n", s1.c_str(), s1[0], (int)(0xFF & s1[0]), sizeof(s1[0])); - fprintf(stderr, "test.s2 '%s' %03d, %03d, size %zu\n", s2.c_str(), s2[0], (int)(0xFF & s2[0]), sizeof(s2[0])); + fprintf(stderr, "test.s1 '%s' %03d, %03d, size %zu\n", s1.c_str(), (int)s1[0], (int)(0xFF & s1[0]), sizeof(s1[0])); + fprintf(stderr, "test.s2 '%s' %03d, %03d, size %zu\n", s2.c_str(), (int)s2[0], (int)(0xFF & s2[0]), sizeof(s2[0])); } { // UTF-8 (or codepage 437) <-> ASCII collision const std::wstring s1 = L"Ç"; const std::wstring s2 = L"é"; - fprintf(stderr, "test.s1 %03d, %03d, size %zu\n", s1[0], (int)(0xFFFF & s1[0]), sizeof(s1[0])); - fprintf(stderr, "test.s2 %03d, %03d, size %zu\n", s2[0], (int)(0xFFFF & s2[0]), sizeof(s2[0])); + fprintf(stderr, "test.s1 %03d, %03d, size %zu\n", (int)s1[0], (int)(0xFFFF & s1[0]), sizeof(s1[0])); + fprintf(stderr, "test.s2 %03d, %03d, size %zu\n", (int)s2[0], (int)(0xFFFF & s2[0]), sizeof(s2[0])); } const std::string r1_max = jau::dec_to_radix(base-1, base, 3, '0'); -- cgit v1.2.3