From d8a60c0145f27c3e713d748c6136e0dbcb94f6b1 Mon Sep 17 00:00:00 2001 From: phancb Date: Thu, 28 Dec 2023 02:02:05 +0800 Subject: [PATCH] Fix narrowing conversion error on riscv64 Signed-off-by: phancb --- tests/utils/StringUtils_tests.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/utils/StringUtils_tests.cpp b/tests/utils/StringUtils_tests.cpp index 0154a4fc18..e258832b17 100644 --- a/tests/utils/StringUtils_tests.cpp +++ b/tests/utils/StringUtils_tests.cpp @@ -53,7 +53,7 @@ OCIO_ADD_TEST(StringUtils, trim) { // Test that no assert happens when the Trim argument is not an unsigned char (see issue #1874). - constexpr char ref2[]{ -1, -2, -3, '\0' }; + constexpr char ref2[]{ char(-1), char(-2), char(-3), '\0' }; const std::string str = StringUtils::Trim(ref2); } }