2007-10-31 22:40:34 +00:00
|
|
|
// -*- C++ -*-
|
|
|
|
|
|
|
|
// Heavily inspired by /usr/include/c++/4.1/bits
|
|
|
|
//
|
|
|
|
// Copyright (C) 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
|
|
|
|
// terms of the GNU General Public License as published by the
|
|
|
|
// Free Software Foundation; either version 2, or (at your option)
|
|
|
|
// any later version.
|
|
|
|
|
|
|
|
#ifndef STRFWD_H
|
|
|
|
#define STRFWD_H
|
|
|
|
|
|
|
|
#ifdef USE_WCHAR_T
|
|
|
|
|
|
|
|
// Prefer this if possible because GNU libstdc++ has usable
|
|
|
|
// std::ctype<wchar_t> locale facets but not
|
|
|
|
// std::ctype<boost::uint32_t>. gcc older than 3.4 is also missing
|
|
|
|
// usable std::char_traits<boost::uint32_t>.
|
|
|
|
namespace lyx { typedef wchar_t char_type; }
|
|
|
|
|
|
|
|
#else
|
|
|
|
|
|
|
|
#include <boost/cstdint.hpp>
|
2007-10-31 23:41:22 +00:00
|
|
|
namespace lyx { typedef boost::uint32_t char_type; }
|
2007-10-31 22:40:34 +00:00
|
|
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
2007-11-01 22:17:22 +00:00
|
|
|
namespace std {
|
2007-10-31 22:40:34 +00:00
|
|
|
|
2007-11-01 22:17:22 +00:00
|
|
|
template<typename Char> struct char_traits;
|
|
|
|
template<> struct char_traits<char>;
|
2007-11-07 22:20:13 +00:00
|
|
|
#ifdef USE_WCHAR_T
|
|
|
|
template<> struct char_traits<wchar_t>;
|
|
|
|
#endif
|
2007-10-31 22:40:34 +00:00
|
|
|
|
2007-11-01 22:17:22 +00:00
|
|
|
template<typename Alloc> class allocator;
|
2007-10-31 22:40:34 +00:00
|
|
|
|
2007-11-01 22:17:22 +00:00
|
|
|
template<typename Char, typename Traits, typename Alloc> class basic_string;
|
2007-10-31 22:40:34 +00:00
|
|
|
|
2007-11-01 22:17:22 +00:00
|
|
|
typedef basic_string<char, char_traits<char>, allocator<char> > string;
|
2007-10-31 22:40:34 +00:00
|
|
|
|
2007-11-01 22:17:22 +00:00
|
|
|
template<class Char, class Traits> class basic_istream;
|
|
|
|
template<class Char, class Traits> class basic_ostream;
|
2007-10-31 22:40:34 +00:00
|
|
|
|
2007-11-01 22:17:22 +00:00
|
|
|
typedef basic_istream<char, char_traits<char> > istream;
|
|
|
|
typedef basic_ostream<char, char_traits<char> > ostream;
|
2007-10-31 22:40:34 +00:00
|
|
|
|
2007-11-01 22:17:22 +00:00
|
|
|
}
|
2007-10-31 22:40:34 +00:00
|
|
|
|
|
|
|
|
2007-11-01 22:17:22 +00:00
|
|
|
namespace lyx {
|
2007-10-31 22:40:34 +00:00
|
|
|
|
2007-11-01 22:17:22 +00:00
|
|
|
typedef std::basic_string<char_type, std::char_traits<char_type>,
|
|
|
|
std::allocator<char_type> > docstring;
|
2007-10-31 22:40:34 +00:00
|
|
|
|
2007-11-01 22:17:22 +00:00
|
|
|
/// Base class for UCS4 input streams
|
|
|
|
typedef std::basic_istream<char_type, std::char_traits<char_type> >
|
|
|
|
idocstream;
|
2007-10-31 22:40:34 +00:00
|
|
|
|
2007-11-01 22:17:22 +00:00
|
|
|
/// Base class for UCS4 output streams
|
|
|
|
typedef std::basic_ostream<char_type, std::char_traits<char_type> >
|
|
|
|
odocstream;
|
2007-10-31 22:40:34 +00:00
|
|
|
|
|
|
|
|
|
|
|
} // namespace lyx
|
|
|
|
|
|
|
|
#endif
|