summaryrefslogtreecommitdiffstats
path: root/libstdc++-v3/include/bits/basic_ios.h
diff options
context:
space:
mode:
authorbkoz <bkoz@138bc75d-0d04-0410-961f-82ee72b054a4>2002-01-25 06:36:32 +0000
committerbkoz <bkoz@138bc75d-0d04-0410-961f-82ee72b054a4>2002-01-25 06:36:32 +0000
commitda9b3b51a4e221a071d52186112357e6e0ce00c3 (patch)
tree147b43df3b19f4ab2a95375185b83cdba58dbace /libstdc++-v3/include/bits/basic_ios.h
parent8250ae22de60a5a6da47c1d02628a78dd689d251 (diff)
downloadppe42-gcc-da9b3b51a4e221a071d52186112357e6e0ce00c3.tar.gz
ppe42-gcc-da9b3b51a4e221a071d52186112357e6e0ce00c3.zip
2002-01-24 Benjamin Kosnik <bkoz@redhat.com>
* testsuite/27_io/ostream_inserter_char.cc (test07): New. 2002-01-24 Benjamin Kosnik <bkoz@redhat.com> * include/bits/basic_ios.h (basic_ios::_M_check_facet): Make const, tweak. (basic_ios::fill(char_type)): Use fill(). * include/bits/basic_ios.tcc (basic_ios::widen): Use _M_check_facet. (basic_ios::narrow): Same. (basic_ios::_M_cache_facets): Explicitly set cached facets to zero if they are invalid. (basic_ios::init): Comment. * testsuite/27_io/ios_init.cc (test02): New. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@49205 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libstdc++-v3/include/bits/basic_ios.h')
-rw-r--r--libstdc++-v3/include/bits/basic_ios.h16
1 files changed, 6 insertions, 10 deletions
diff --git a/libstdc++-v3/include/bits/basic_ios.h b/libstdc++-v3/include/bits/basic_ios.h
index cc393aaf311..f680a508206 100644
--- a/libstdc++-v3/include/bits/basic_ios.h
+++ b/libstdc++-v3/include/bits/basic_ios.h
@@ -1,6 +1,6 @@
// Iostreams base classes -*- C++ -*-
-// Copyright (C) 1997, 1998, 1999, 2001 Free Software Foundation, Inc.
+// Copyright (C) 1997, 1998, 1999, 2001, 2002 Free Software Foundation, Inc.
//
// This file is part of the GNU ISO C++ Library. This library is free
// software; you can redistribute it and/or modify it under the
@@ -62,12 +62,11 @@ namespace std
typedef num_get<_CharT, __istreambuf_iter> __numget_type;
// Data members:
- private:
+ protected:
basic_ostream<_CharT, _Traits>* _M_tie;
char_type _M_fill;
iostate _M_exception;
- protected:
basic_streambuf<_CharT, _Traits>* _M_streambuf;
iostate _M_streambuf_state;
@@ -174,7 +173,7 @@ namespace std
inline char_type
fill(char_type __ch)
{
- char_type __old = _M_fill;
+ char_type __old = this->fill();
_M_fill = __ch;
return __old;
}
@@ -198,14 +197,11 @@ namespace std
init(basic_streambuf<_CharT, _Traits>* __sb);
bool
- _M_check_facet(const locale::facet* __f)
+ _M_check_facet(const locale::facet* __f) const
{
- bool __ret = false;
- if (__f)
- __ret = true;
- else
+ if (!__f)
__throw_bad_cast();
- return __ret;
+ return true;
}
void
OpenPOWER on IntegriCloud