Fix encoding() and max_length() values for codecvt facets
authorJonathan Wakely <jwakely@redhat.com>
Thu, 16 Mar 2017 15:27:57 +0000 (15:27 +0000)
committerJonathan Wakely <redi@gcc.gnu.org>
Thu, 16 Mar 2017 15:27:57 +0000 (15:27 +0000)
commit516231de7317bbaf0f83a27047924bb690a217e5
treeb2ce70fd6aaa1d1beff946081aa9e670e1441d64
parentbcd682e1faed71fd861518ca43235706fc39a7cd
Fix encoding() and max_length() values for codecvt facets

* src/c++11/codecvt.cc (codecvt<char16_t, char, mbstate_t>)
(codecvt<char32_t, char, mbstate_t>, __codecvt_utf8_base<char16_t>)
(__codecvt_utf8_base<char32_t>, __codecvt_utf8_base<wchar_t>)
(__codecvt_utf16_base<char16_t>, __codecvt_utf16_base<char32_t>)
(__codecvt_utf16_base<wchar_t>, __codecvt_utf8_utf16_base<char16_t>)
(__codecvt_utf8_utf16_base<char32_t>)
(__codecvt_utf8_utf16_base<wchar_t>): Fix do_encoding() and
do_max_length() return values.
* testsuite/22_locale/codecvt/codecvt_utf16/members.cc: New test.
* testsuite/22_locale/codecvt/codecvt_utf8/members.cc: New test.
* testsuite/22_locale/codecvt/codecvt_utf8_utf16/members.cc: New test.

From-SVN: r246201
libstdc++-v3/ChangeLog
libstdc++-v3/src/c++11/codecvt.cc
libstdc++-v3/testsuite/22_locale/codecvt/char16_t.cc
libstdc++-v3/testsuite/22_locale/codecvt/codecvt_utf16/members.cc [new file with mode: 0644]
libstdc++-v3/testsuite/22_locale/codecvt/codecvt_utf8/members.cc [new file with mode: 0644]
libstdc++-v3/testsuite/22_locale/codecvt/codecvt_utf8_utf16/members.cc [new file with mode: 0644]