std_bitset.h (operator>>): Change to char_type.

2000-09-18  Yuri V. Baskakov  <yuribsk@lab.sun.mcst.ru>

	* bits/std_bitset.h (operator>>): Change to char_type.

From-SVN: r36505
This commit is contained in:
Yuri V. Baskakov 2000-09-18 18:08:46 +00:00 committed by Benjamin Kosnik
parent d340408c13
commit b4927ead98
2 changed files with 7 additions and 2 deletions

View File

@ -1,3 +1,7 @@
2000-09-18 Yuri V. Baskakov <yuribsk@lab.sun.mcst.ru>
* bits/std_bitset.h (operator>>): Change to char_type.
2000-09-15 Benjamin Kosnik <bkoz@purist.soma.redhat.com>
* src/locale.cc (locale::locale(const char* __name)): Consolidate

View File

@ -848,6 +848,7 @@ template <class _CharT, class _Traits, size_t _Nb>
basic_istream<_CharT, _Traits>&
operator>>(basic_istream<_CharT, _Traits>& __is, bitset<_Nb>& __x)
{
typedef typename _Traits::char_type char_type;
basic_string<_CharT, _Traits> __tmp;
__tmp.reserve(_Nb);
@ -864,8 +865,8 @@ operator>>(basic_istream<_CharT, _Traits>& __is, bitset<_Nb>& __x)
break;
}
else {
char __c2 = _Traits::to_char_type(__c1);
char __c = __is.narrow(__c2, '*');
char_type __c2 = _Traits::to_char_type(__c1);
char_type __c = __is.narrow(__c2, '*');
if (__c == '0' || __c == '1')
__tmp.push_back(__c);