aboutsummaryrefslogtreecommitdiffstats
path: root/test/test_basictypeconv.cpp
diff options
context:
space:
mode:
authorSven Gothel <[email protected]>2022-09-03 04:59:01 +0200
committerSven Gothel <[email protected]>2022-09-03 04:59:01 +0200
commitee3f67bfd08763701deaec40f98c01786d94817a (patch)
tree439448a9153554a46d3802a4deb620193cd389b9 /test/test_basictypeconv.cpp
parentd4d9c93568bdaceaf68b1d0e2196af8f3ccc0caf (diff)
test_basictypeconv.cpp: Fix int format for 32bit compilation
Diffstat (limited to 'test/test_basictypeconv.cpp')
-rw-r--r--test/test_basictypeconv.cpp8
1 files changed, 4 insertions, 4 deletions
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');