You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
libcxx/test/std/input.output/iostream.format/ext.manip
Stephan T. Lavavej c53fd92b0f [libcxx] [test] Fix MSVC warning C4244 "conversion from 'X' to 'Y', possible loss of data", part 1/7.
Given `std::basic_streambuf<CharT>::int_type __c`, `std::basic_string<CharT> str_`,
and having checked `__c != std::basic_streambuf<CharT>::traits_type::eof()` (substituting typedefs
for clarity), the line `str_.push_back(__c);` is safe according to humans, but truncates according
to compilers. `str_.push_back(static_cast<CharT>(__c));` avoids that problem.

Fixes D27538.

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@289105 91177308-0d34-0410-b5e6-96231b3b80d8
9 years ago
..
get_money.pass.cpp Move test into test/std subdirectory. 11 years ago
get_time.pass.cpp Fix warnings in tests. 10 years ago
put_money.pass.cpp Move test into test/std subdirectory. 11 years ago
put_time.pass.cpp [libcxx] [test] Fix MSVC warning C4244 "conversion from 'X' to 'Y', possible loss of data", part 1/7. 9 years ago