aboutsummaryrefslogtreecommitdiff
path: root/libstdc++-v3/include/bits/istream.tcc
diff options
context:
space:
mode:
Diffstat (limited to 'libstdc++-v3/include/bits/istream.tcc')
-rw-r--r--libstdc++-v3/include/bits/istream.tcc68
1 files changed, 35 insertions, 33 deletions
diff --git a/libstdc++-v3/include/bits/istream.tcc b/libstdc++-v3/include/bits/istream.tcc
index a6e49a923bd..f4508345065 100644
--- a/libstdc++-v3/include/bits/istream.tcc
+++ b/libstdc++-v3/include/bits/istream.tcc
@@ -1,6 +1,6 @@
// istream classes -*- C++ -*-
-// Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002
+// Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003
// Free Software Foundation, Inc.
//
// This file is part of the GNU ISO C++ Library. This library is free
@@ -122,7 +122,7 @@ namespace std
{
// 27.6.1.2.1 Common requirements.
// Turn this on without causing an ios::failure to be thrown.
- this->setstate(ios_base::badbit);
+ this->_M_setstate(ios_base::badbit);
if ((this->exceptions() & ios_base::badbit) != 0)
__throw_exception_again;
}
@@ -159,7 +159,7 @@ namespace std
{
// 27.6.1.2.1 Common requirements.
// Turn this on without causing an ios::failure to be thrown.
- this->setstate(ios_base::badbit);
+ this->_M_setstate(ios_base::badbit);
if ((this->exceptions() & ios_base::badbit) != 0)
__throw_exception_again;
}
@@ -186,7 +186,7 @@ namespace std
{
// 27.6.1.2.1 Common requirements.
// Turn this on without causing an ios::failure to be thrown.
- this->setstate(ios_base::badbit);
+ this->_M_setstate(ios_base::badbit);
if ((this->exceptions() & ios_base::badbit) != 0)
__throw_exception_again;
}
@@ -223,7 +223,7 @@ namespace std
{
// 27.6.1.2.1 Common requirements.
// Turn this on without causing an ios::failure to be thrown.
- this->setstate(ios_base::badbit);
+ this->_M_setstate(ios_base::badbit);
if ((this->exceptions() & ios_base::badbit) != 0)
__throw_exception_again;
}
@@ -250,7 +250,7 @@ namespace std
{
// 27.6.1.2.1 Common requirements.
// Turn this on without causing an ios::failure to be thrown.
- this->setstate(ios_base::badbit);
+ this->_M_setstate(ios_base::badbit);
if ((this->exceptions() & ios_base::badbit) != 0)
__throw_exception_again;
}
@@ -277,7 +277,7 @@ namespace std
{
// 27.6.1.2.1 Common requirements.
// Turn this on without causing an ios::failure to be thrown.
- this->setstate(ios_base::badbit);
+ this->_M_setstate(ios_base::badbit);
if ((this->exceptions() & ios_base::badbit) != 0)
__throw_exception_again;
}
@@ -304,7 +304,7 @@ namespace std
{
// 27.6.1.2.1 Common requirements.
// Turn this on without causing an ios::failure to be thrown.
- this->setstate(ios_base::badbit);
+ this->_M_setstate(ios_base::badbit);
if ((this->exceptions() & ios_base::badbit) != 0)
__throw_exception_again;
}
@@ -332,7 +332,7 @@ namespace std
{
// 27.6.1.2.1 Common requirements.
// Turn this on without causing an ios::failure to be thrown.
- this->setstate(ios_base::badbit);
+ this->_M_setstate(ios_base::badbit);
if ((this->exceptions() & ios_base::badbit) != 0)
__throw_exception_again;
}
@@ -359,7 +359,7 @@ namespace std
{
// 27.6.1.2.1 Common requirements.
// Turn this on without causing an ios::failure to be thrown.
- this->setstate(ios_base::badbit);
+ this->_M_setstate(ios_base::badbit);
if ((this->exceptions() & ios_base::badbit) != 0)
__throw_exception_again;
}
@@ -387,7 +387,7 @@ namespace std
{
// 27.6.1.2.1 Common requirements.
// Turn this on without causing an ios::failure to be thrown.
- this->setstate(ios_base::badbit);
+ this->_M_setstate(ios_base::badbit);
if ((this->exceptions() & ios_base::badbit) != 0)
__throw_exception_again;
}
@@ -414,7 +414,7 @@ namespace std
{
// 27.6.1.2.1 Common requirements.
// Turn this on without causing an ios::failure to be thrown.
- this->setstate(ios_base::badbit);
+ this->_M_setstate(ios_base::badbit);
if ((this->exceptions() & ios_base::badbit) != 0)
__throw_exception_again;
}
@@ -441,7 +441,7 @@ namespace std
{
// 27.6.1.2.1 Common requirements.
// Turn this on without causing an ios::failure to be thrown.
- this->setstate(ios_base::badbit);
+ this->_M_setstate(ios_base::badbit);
if ((this->exceptions() & ios_base::badbit) != 0)
__throw_exception_again;
}
@@ -468,7 +468,7 @@ namespace std
{
// 27.6.1.2.1 Common requirements.
// Turn this on without causing an ios::failure to be thrown.
- this->setstate(ios_base::badbit);
+ this->_M_setstate(ios_base::badbit);
if ((this->exceptions() & ios_base::badbit) != 0)
__throw_exception_again;
}
@@ -499,7 +499,7 @@ namespace std
{
// 27.6.2.5.1 Common requirements.
// Turn this on without causing an ios::failure to be thrown.
- this->setstate(ios_base::badbit);
+ this->_M_setstate(ios_base::badbit);
if ((this->exceptions() & ios_base::badbit) != 0)
__throw_exception_again;
}
@@ -531,7 +531,7 @@ namespace std
{
// 27.6.1.3 paragraph 1
// Turn this on without causing an ios::failure to be thrown.
- this->setstate(ios_base::badbit);
+ this->_M_setstate(ios_base::badbit);
if ((this->exceptions() & ios_base::badbit) != 0)
__throw_exception_again;
}
@@ -565,7 +565,7 @@ namespace std
{
// 27.6.1.3 paragraph 1
// Turn this on without causing an ios::failure to be thrown.
- this->setstate(ios_base::badbit);
+ this->_M_setstate(ios_base::badbit);
if ((this->exceptions() & ios_base::badbit) != 0)
__throw_exception_again;
}
@@ -604,7 +604,7 @@ namespace std
{
// 27.6.1.3 paragraph 1
// Turn this on without causing an ios::failure to be thrown.
- this->setstate(ios_base::badbit);
+ this->_M_setstate(ios_base::badbit);
if ((this->exceptions() & ios_base::badbit) != 0)
__throw_exception_again;
}
@@ -647,7 +647,7 @@ namespace std
{
// 27.6.1.3 paragraph 1
// Turn this on without causing an ios::failure to be thrown.
- this->setstate(ios_base::badbit);
+ this->_M_setstate(ios_base::badbit);
if ((this->exceptions() & ios_base::badbit) != 0)
__throw_exception_again;
}
@@ -698,7 +698,7 @@ namespace std
{
// 27.6.1.3 paragraph 1
// Turn this on without causing an ios::failure to be thrown.
- this->setstate(ios_base::badbit);
+ this->_M_setstate(ios_base::badbit);
if ((this->exceptions() & ios_base::badbit) != 0)
__throw_exception_again;
}
@@ -739,7 +739,7 @@ namespace std
{
// 27.6.1.3 paragraph 1
// Turn this on without causing an ios::failure to be thrown.
- this->setstate(ios_base::badbit);
+ this->_M_setstate(ios_base::badbit);
if ((this->exceptions() & ios_base::badbit) != 0)
__throw_exception_again;
}
@@ -763,7 +763,7 @@ namespace std
{
// 27.6.1.3 paragraph 1
// Turn this on without causing an ios::failure to be thrown.
- this->setstate(ios_base::badbit);
+ this->_M_setstate(ios_base::badbit);
if ((this->exceptions() & ios_base::badbit) != 0)
__throw_exception_again;
}
@@ -790,7 +790,7 @@ namespace std
{
// 27.6.1.3 paragraph 1
// Turn this on without causing an ios::failure to be thrown.
- this->setstate(ios_base::badbit);
+ this->_M_setstate(ios_base::badbit);
if ((this->exceptions() & ios_base::badbit) != 0)
__throw_exception_again;
}
@@ -826,7 +826,7 @@ namespace std
{
// 27.6.1.3 paragraph 1
// Turn this on without causing an ios::failure to be thrown.
- this->setstate(ios_base::badbit);
+ this->_M_setstate(ios_base::badbit);
if ((this->exceptions() & ios_base::badbit) != 0)
__throw_exception_again;
}
@@ -856,7 +856,7 @@ namespace std
{
// 27.6.1.3 paragraph 1
// Turn this on without causing an ios::failure to be thrown.
- this->setstate(ios_base::badbit);
+ this->_M_setstate(ios_base::badbit);
if ((this->exceptions() & ios_base::badbit) != 0)
__throw_exception_again;
}
@@ -887,7 +887,7 @@ namespace std
{
// 27.6.1.3 paragraph 1
// Turn this on without causing an ios::failure to be thrown.
- this->setstate(ios_base::badbit);
+ this->_M_setstate(ios_base::badbit);
if ((this->exceptions() & ios_base::badbit) != 0)
__throw_exception_again;
}
@@ -922,7 +922,7 @@ namespace std
{
// 27.6.1.3 paragraph 1
// Turn this on without causing an ios::failure to be thrown.
- this->setstate(ios_base::badbit);
+ this->_M_setstate(ios_base::badbit);
if ((this->exceptions() & ios_base::badbit) != 0)
__throw_exception_again;
}
@@ -998,7 +998,7 @@ namespace std
{
// 27.6.1.2.1 Common requirements.
// Turn this on without causing an ios::failure to be thrown.
- __in.setstate(ios_base::badbit);
+ __in._M_setstate(ios_base::badbit);
if ((__in.exceptions() & ios_base::badbit) != 0)
__throw_exception_again;
}
@@ -1036,9 +1036,9 @@ namespace std
while (__extracted < __num - 1
&& !_Traits::eq_int_type(__c, __eof)
- && !__ctype.is(ctype_base::space, __c))
+ && !__ctype.is(ctype_base::space, _Traits::to_char_type(__c)))
{
- *__s++ = __c;
+ *__s++ = _Traits::to_char_type(__c);
++__extracted;
__c = __sb->snextc();
}
@@ -1055,7 +1055,7 @@ namespace std
{
// 27.6.1.2.1 Common requirements.
// Turn this on without causing an ios::failure to be thrown.
- __in.setstate(ios_base::badbit);
+ __in._M_setstate(ios_base::badbit);
if ((__in.exceptions() & ios_base::badbit) != 0)
__throw_exception_again;
}
@@ -1081,7 +1081,7 @@ namespace std
__int_type __c = __sb->sgetc();
while (!_Traits::eq_int_type(__c, __eof)
- && __ctype.is(ctype_base::space, __c))
+ && __ctype.is(ctype_base::space, _Traits::to_char_type(__c)))
__c = __sb->snextc();
if (_Traits::eq_int_type(__c, __eof))
@@ -1119,7 +1119,7 @@ namespace std
while (__extracted < __n
&& !_Traits::eq_int_type(__c, __eof)
- && !__ctype.is(ctype_base::space, __c))
+ && !__ctype.is(ctype_base::space, _Traits::to_char_type(__c)))
{
__str += _Traits::to_char_type(__c);
++__extracted;
@@ -1189,6 +1189,7 @@ namespace std
// Inhibit implicit instantiations for required instantiations,
// which are defined via explicit instantiations elsewhere.
// NB: This syntax is a GNU extension.
+#if _GLIBCPP_EXTERN_TEMPLATE
extern template class basic_istream<char>;
extern template istream& ws(istream&);
extern template istream& operator>>(istream&, char&);
@@ -1204,4 +1205,5 @@ namespace std
extern template wistream& operator>>(wistream&, wchar_t&);
extern template wistream& operator>>(wistream&, wchar_t*);
#endif
+#endif
} // namespace std