char_regex_traits.hpp 1.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  1. /*
  2. *
  3. * Copyright (c) 2002
  4. * John Maddock
  5. *
  6. * Use, modification and distribution are subject to the
  7. * Boost Software License, Version 1.0. (See accompanying file
  8. * LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
  9. *
  10. */
  11. /*
  12. * LOCATION: see http://www.boost.org for most recent version.
  13. * FILE char_regex_traits.cpp
  14. * VERSION see <boost/version.hpp>
  15. * DESCRIPTION: Declares deprecated traits classes char_regex_traits<>.
  16. */
  17. #ifndef BOOST_REGEX_V5_CHAR_REGEX_TRAITS_HPP
  18. #define BOOST_REGEX_V5_CHAR_REGEX_TRAITS_HPP
  19. #include <boost/regex/v5/regex_traits.hpp>
  20. namespace boost{
  21. namespace deprecated{
  22. //
  23. // class char_regex_traits_i
  24. // provides case insensitive traits classes (deprecated):
  25. template <class charT>
  26. class char_regex_traits_i : public regex_traits<charT> {};
  27. template<>
  28. class char_regex_traits_i<char> : public regex_traits<char>
  29. {
  30. public:
  31. typedef char char_type;
  32. typedef unsigned char uchar_type;
  33. typedef unsigned int size_type;
  34. typedef regex_traits<char> base_type;
  35. };
  36. #ifndef BOOST_NO_WREGEX
  37. template<>
  38. class char_regex_traits_i<wchar_t> : public regex_traits<wchar_t>
  39. {
  40. public:
  41. typedef wchar_t char_type;
  42. typedef unsigned short uchar_type;
  43. typedef unsigned int size_type;
  44. typedef regex_traits<wchar_t> base_type;
  45. };
  46. #endif
  47. } // namespace deprecated
  48. } // namespace boost
  49. #endif // include