aboutsummaryrefslogtreecommitdiff
path: root/libstdc++-v3/include/bits/char_traits.h
diff options
context:
space:
mode:
authorBenjamin Kosnik <bkoz@gcc.gnu.org>2001-03-07 22:22:41 +0000
committerBenjamin Kosnik <bkoz@gcc.gnu.org>2001-03-07 22:22:41 +0000
commitd32c94be18c4dfb2bd8df6507e178455cc3212a3 (patch)
tree1b3a74319ba47ca42f9732a30368fa98541f158a /libstdc++-v3/include/bits/char_traits.h
parentda1cb0929e188b4e4db3415377f97f7065f7ab69 (diff)
downloadgcc-d32c94be18c4dfb2bd8df6507e178455cc3212a3.zip
gcc-d32c94be18c4dfb2bd8df6507e178455cc3212a3.tar.gz
gcc-d32c94be18c4dfb2bd8df6507e178455cc3212a3.tar.bz2
std_iosfwd.h: Remove string forward decls here.
2001-03-07 Benjamin Kosnik <bkoz@redhat.com> * include/bits/std_iosfwd.h: Remove string forward decls here. * include/bits/stringfwd.h: Add forward decls for char_traits specializations. * config/c_io_libio.h (wstreamoff): Delete. * config/c_io_stdio.h (wstreamoff): Same. * include/bits/char_traits.h: Use streamoff not wstreamoff for char_traits<wchar_t>::off_type. Remove duplicate typedefs. * include/bits/fpos.h: Define streampos/wstreampos here. * testsuite/27_io/istream_seeks.cc (test04): Explicitly cast int values to off_type. (test05): Same. Changeup output files. * testsuite/27_io/istream_unformatted.cc: Change output files. * testsuite/27_io/istream_seeks-1.txt: Add. * testsuite/27_io/istream_seeks-2.tst: Add. * testsuite/27_io/istream_seeks-1.tst: Add. * testsuite/27_io/istream_unformatted-2.tst: Delete. * testsuite/27_io/istream_unformatted-3.tst: Delete. * testsuite/27_io/istream_unformatted-3.txt: Delete. From-SVN: r40303
Diffstat (limited to 'libstdc++-v3/include/bits/char_traits.h')
-rw-r--r--libstdc++-v3/include/bits/char_traits.h26
1 files changed, 5 insertions, 21 deletions
diff --git a/libstdc++-v3/include/bits/char_traits.h b/libstdc++-v3/include/bits/char_traits.h
index bb8b371..b98a304 100644
--- a/libstdc++-v3/include/bits/char_traits.h
+++ b/libstdc++-v3/include/bits/char_traits.h
@@ -36,28 +36,14 @@
#pragma GCC system_header
-#include <bits/std_cwchar.h> // For mbstate_t.
#include <bits/std_cstring.h> // For memmove, memset, memchr
-#include <bits/fpos.h> // For streamoff, streamsize
-
-namespace std {
-
- // Same as iosfwd
-#ifdef _GLIBCPP_RESOLVE_LIB_DEFECTS
- // Can't have self-recursive types for streampos.
- // 21.1.3.1 char_traits sets size_type to streampos
- // 27.4.1
- // And here, where streampos is typedefed to fpos<traits::state_type>
- typedef fpos<mbstate_t> streampos;
-# ifdef _GLIBCPP_USE_WCHAR_T
- typedef fpos<mbstate_t> wstreampos;
-# endif
-#endif
+#include <bits/fpos.h> // For streampos
+namespace std
+{
// 21.1.2 Basis for explicit _Traits specialization
// NB: That for any given actual character type this definition is
// probably wrong.
-
template<class _CharT>
struct char_traits
{
@@ -216,7 +202,7 @@ namespace std {
{
typedef wchar_t char_type;
typedef wint_t int_type;
- typedef wstreamoff off_type;
+ typedef streamoff off_type;
typedef wstreampos pos_type;
typedef mbstate_t state_type;
@@ -287,6 +273,4 @@ namespace std {
} // namespace std
-
-#endif /* _CPP_BITS_CHAR_TRAITS_H */
-
+#endif