KEMBAR78
`VSO_0180466_algorithm_overhauls`: Suppress `-Wcharacter-conversion` for Clang 21 by YexuanXiao · Pull Request #5657 · microsoft/STL · GitHub
Skip to content

Conversation

@YexuanXiao
Copy link
Contributor

Lines 35-84 of this test involve comparisons between different charN_t types, so similar to #5653, Clang will also generate warnings for this.

template <template <class, class> class Test, class Left>
void test_all_numeric_types_impl() {
Test<Left, char>{}();
Test<Left, signed char>{}();
Test<Left, unsigned char>{}();
Test<Left, wchar_t>{}();
#ifdef __cpp_char8_t
Test<Left, char8_t>{}();
#endif // __cpp_char8_t
Test<Left, char16_t>{}();
Test<Left, char32_t>{}();
Test<Left, short>{}();
Test<Left, unsigned short>{}();
Test<Left, int>{}();
Test<Left, unsigned int>{}();
Test<Left, long>{}();
Test<Left, unsigned long>{}();
Test<Left, long long>{}();
Test<Left, unsigned long long>{}();
Test<Left, float>{}();
Test<Left, double>{}();
Test<Left, long double>{}();
}
template <template <class, class> class Test>
void test_all_numeric_types() {
test_all_numeric_types_impl<Test, char>();
test_all_numeric_types_impl<Test, signed char>();
test_all_numeric_types_impl<Test, unsigned char>();
test_all_numeric_types_impl<Test, wchar_t>();
#ifdef __cpp_char8_t
test_all_numeric_types_impl<Test, char8_t>();
#endif // __cpp_char8_t
test_all_numeric_types_impl<Test, char16_t>();
test_all_numeric_types_impl<Test, char32_t>();
test_all_numeric_types_impl<Test, short>();
test_all_numeric_types_impl<Test, unsigned short>();
test_all_numeric_types_impl<Test, int>();
test_all_numeric_types_impl<Test, unsigned int>();
test_all_numeric_types_impl<Test, long>();
test_all_numeric_types_impl<Test, unsigned long>();
test_all_numeric_types_impl<Test, long long>();
test_all_numeric_types_impl<Test, unsigned long long>();
test_all_numeric_types_impl<Test, float>();
test_all_numeric_types_impl<Test, double>();
test_all_numeric_types_impl<Test, long double>();
#ifdef __cpp_lib_byte
Test<byte, byte>{}();
#endif // __cpp_lib_byte
}

@YexuanXiao YexuanXiao requested a review from a team as a code owner July 26, 2025 09:53
@github-project-automation github-project-automation bot moved this to Initial Review in STL Code Reviews Jul 26, 2025
@StephanTLavavej StephanTLavavej changed the title Suppress -Wcharacter-conversion for tests/VSO_0180466_algorithm_overhauls VSO_0180466_algorithm_overhauls: Suppress -Wcharacter-conversion for Clang 21 Aug 2, 2025
@StephanTLavavej StephanTLavavej added the test Related to test code label Aug 2, 2025
@StephanTLavavej StephanTLavavej moved this from Initial Review to Ready To Merge in STL Code Reviews Aug 2, 2025
@StephanTLavavej StephanTLavavej moved this from Ready To Merge to Merging in STL Code Reviews Aug 7, 2025
@StephanTLavavej
Copy link
Member

I'm mirroring this to the MSVC-internal repo - please notify me if any further changes are pushed.

@StephanTLavavej StephanTLavavej merged commit 1d5f1aa into microsoft:main Aug 8, 2025
39 checks passed
@github-project-automation github-project-automation bot moved this from Merging to Done in STL Code Reviews Aug 8, 2025
@StephanTLavavej
Copy link
Member

⚠️ 🤐 ⚠️

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

test Related to test code

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

2 participants