imgtools/imglib/boostlibrary/boost/regex/concepts.hpp
author Ross Qin <ross.qin@nokia.com>
Thu, 28 Oct 2010 11:18:50 +0800
changeset 667 a3b39a14147a
parent 600 6d08f4a05d93
permissions -rw-r--r--
Remove the PrintingServices component from TB10.1 on wards(on behalf of dane.waby@nokia.com)
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
600
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
     1
/*
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
     2
 *
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
     3
 * Copyright (c) 2004
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
     4
 * John Maddock
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
     5
 *
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
     6
 * Use, modification and distribution are subject to the 
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
     7
 * Boost Software License, Version 1.0. (See accompanying file 
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
     8
 * LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
     9
 *
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    10
 */
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    11
 
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    12
 /*
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    13
  *   LOCATION:    see http://www.boost.org for most recent version.
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    14
  *   FILE         concepts.hpp
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    15
  *   VERSION      see <boost/version.hpp>
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    16
  *   DESCRIPTION: Declares regular expression concepts.
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    17
  */
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    18
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    19
#ifndef BOOST_REGEX_CONCEPTS_HPP_INCLUDED
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    20
#define BOOST_REGEX_CONCEPTS_HPP_INCLUDED
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    21
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    22
#include <boost/concept_archetype.hpp>
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    23
#include <boost/concept_check.hpp>
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    24
#include <boost/type_traits/is_enum.hpp>
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    25
#include <boost/type_traits/is_base_and_derived.hpp>
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    26
#include <boost/static_assert.hpp>
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    27
#ifndef BOOST_TEST_TR1_REGEX
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    28
#include <boost/regex.hpp>
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    29
#endif
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    30
#include <bitset>
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    31
#include <vector>
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    32
#include <iostream>
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    33
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    34
namespace boost{
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    35
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    36
//
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    37
// bitmask_archetype:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    38
// this can be either an integer type, an enum, or a std::bitset,
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    39
// we use the latter as the architype as it offers the "strictest"
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    40
// of the possible interfaces:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    41
//
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    42
typedef std::bitset<512> bitmask_archetype;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    43
//
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    44
// char_architype:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    45
// A strict model for the character type interface.
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    46
//
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    47
struct char_architype
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    48
{
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    49
   // default constructable:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    50
   char_architype();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    51
   // copy constructable / assignable:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    52
   char_architype(const char_architype&);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    53
   char_architype& operator=(const char_architype&);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    54
   // constructable from an integral value:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    55
   char_architype(unsigned long val);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    56
   // comparable:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    57
   bool operator==(const char_architype&)const;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    58
   bool operator!=(const char_architype&)const;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    59
   bool operator<(const char_architype&)const;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    60
   bool operator<=(const char_architype&)const;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    61
   bool operator>=(const char_architype&)const;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    62
   bool operator>(const char_architype&)const;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    63
   // conversion to integral type:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    64
   operator long()const;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    65
};
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    66
//
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    67
// char_architype can not be used with basic_string:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    68
//
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    69
} // namespace boost
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    70
namespace std{
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    71
   template<> struct char_traits<boost::char_architype>
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    72
   {
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    73
      // The intent is that this template is not instantiated,
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    74
      // but this typedef gives us a chance of compilation in
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    75
      // case it is:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    76
      typedef boost::char_architype char_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    77
   };
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    78
}
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    79
namespace boost{
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    80
//
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    81
// regex_traits_architype:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    82
// A strict interpretation of the regular expression traits class requirements.
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    83
//
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    84
template <class charT>
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    85
struct regex_traits_architype
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    86
{
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    87
public:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    88
   regex_traits_architype();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    89
   typedef charT char_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    90
   // typedef std::size_t size_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    91
   typedef std::vector<char_type> string_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    92
   typedef copy_constructible_archetype<assignable_archetype<> > locale_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    93
   typedef bitmask_archetype char_class_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    94
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    95
   static std::size_t length(const char_type* ) { return 0; }
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    96
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    97
   charT translate(charT ) const { return charT(); }
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    98
   charT translate_nocase(charT ) const { return static_object<charT>::get(); }
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    99
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   100
   template <class ForwardIterator>
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   101
   string_type transform(ForwardIterator , ForwardIterator ) const
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   102
   { return static_object<string_type>::get(); }
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   103
   template <class ForwardIterator>
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   104
   string_type transform_primary(ForwardIterator , ForwardIterator ) const
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   105
   { return static_object<string_type>::get(); }
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   106
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   107
   template <class ForwardIterator>
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   108
   char_class_type lookup_classname(ForwardIterator , ForwardIterator ) const
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   109
   { return static_object<char_class_type>::get(); }
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   110
   template <class ForwardIterator>
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   111
   string_type lookup_collatename(ForwardIterator , ForwardIterator ) const
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   112
   { return static_object<string_type>::get(); }
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   113
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   114
   bool isctype(charT, char_class_type) const
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   115
   { return false; }
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   116
   int value(charT, int) const
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   117
   { return 0; }
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   118
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   119
   locale_type imbue(locale_type l)
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   120
   { return l; }
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   121
   locale_type getloc()const
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   122
   { return static_object<locale_type>::get(); }
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   123
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   124
private:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   125
   // this type is not copyable:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   126
   regex_traits_architype(const regex_traits_architype&);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   127
   regex_traits_architype& operator=(const regex_traits_architype&);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   128
};
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   129
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   130
//
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   131
// alter this to std::tr1, to test a std implementation:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   132
//
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   133
#ifndef BOOST_TEST_TR1_REGEX
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   134
namespace global_regex_namespace = ::boost;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   135
#else
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   136
namespace global_regex_namespace = ::std::tr1;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   137
#endif
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   138
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   139
template <class Bitmask>
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   140
struct BitmaskConcept
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   141
{
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   142
   void constraints() 
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   143
   {
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   144
      function_requires<CopyConstructibleConcept<Bitmask> >();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   145
      function_requires<AssignableConcept<Bitmask> >();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   146
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   147
      m_mask1 = m_mask2 | m_mask3;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   148
      m_mask1 = m_mask2 & m_mask3;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   149
      m_mask1 = m_mask2 ^ m_mask3;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   150
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   151
      m_mask1 = ~m_mask2;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   152
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   153
      m_mask1 |= m_mask2;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   154
      m_mask1 &= m_mask2;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   155
      m_mask1 ^= m_mask2;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   156
   }
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   157
   Bitmask m_mask1, m_mask2, m_mask3;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   158
};
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   159
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   160
template <class traits>
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   161
struct RegexTraitsConcept
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   162
{
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   163
   RegexTraitsConcept();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   164
   // required typedefs:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   165
   typedef typename traits::char_type char_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   166
   // typedef typename traits::size_type size_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   167
   typedef typename traits::string_type string_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   168
   typedef typename traits::locale_type locale_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   169
   typedef typename traits::char_class_type char_class_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   170
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   171
   void constraints() 
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   172
   {
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   173
      //function_requires<UnsignedIntegerConcept<size_type> >();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   174
      function_requires<RandomAccessContainerConcept<string_type> >();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   175
      function_requires<DefaultConstructibleConcept<locale_type> >();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   176
      function_requires<CopyConstructibleConcept<locale_type> >();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   177
      function_requires<AssignableConcept<locale_type> >();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   178
      function_requires<BitmaskConcept<char_class_type> >();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   179
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   180
      std::size_t n = traits::length(m_pointer);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   181
      ignore_unused_variable_warning(n);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   182
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   183
      char_type c = m_ctraits.translate(m_char);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   184
      ignore_unused_variable_warning(c);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   185
      c = m_ctraits.translate_nocase(m_char);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   186
      
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   187
      //string_type::foobar bar;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   188
      string_type s1 = m_ctraits.transform(m_pointer, m_pointer);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   189
      ignore_unused_variable_warning(s1);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   190
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   191
      string_type s2 = m_ctraits.transform_primary(m_pointer, m_pointer);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   192
      ignore_unused_variable_warning(s2);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   193
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   194
      char_class_type cc = m_ctraits.lookup_classname(m_pointer, m_pointer);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   195
      ignore_unused_variable_warning(cc);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   196
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   197
      string_type s3 = m_ctraits.lookup_collatename(m_pointer, m_pointer);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   198
      ignore_unused_variable_warning(s3);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   199
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   200
      bool b = m_ctraits.isctype(m_char, cc);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   201
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   202
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   203
      int v = m_ctraits.value(m_char, 16);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   204
      ignore_unused_variable_warning(v);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   205
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   206
      locale_type l(m_ctraits.getloc());
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   207
      m_traits.imbue(l);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   208
      ignore_unused_variable_warning(l);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   209
   }
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   210
   traits m_traits;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   211
   const traits m_ctraits;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   212
   const char_type* m_pointer;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   213
   char_type m_char;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   214
private:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   215
   RegexTraitsConcept& operator=(RegexTraitsConcept&);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   216
};
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   217
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   218
//
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   219
// helper class to compute what traits class a regular expression type is using:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   220
//
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   221
template <class Regex>
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   222
struct regex_traits_computer;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   223
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   224
template <class charT, class traits>
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   225
struct regex_traits_computer< global_regex_namespace::basic_regex<charT, traits> >
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   226
{
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   227
   typedef traits type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   228
};
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   229
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   230
//
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   231
// BaseRegexConcept does not test anything dependent on basic_string,
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   232
// in case our charT does not have an associated char_traits:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   233
//
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   234
template <class Regex>
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   235
struct BaseRegexConcept
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   236
{
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   237
   typedef typename Regex::value_type value_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   238
   //typedef typename Regex::size_type size_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   239
   typedef typename Regex::flag_type flag_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   240
   typedef typename Regex::locale_type locale_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   241
   typedef input_iterator_archetype<value_type> input_iterator_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   242
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   243
   // derived test types:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   244
   typedef const value_type* pointer_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   245
   typedef bidirectional_iterator_archetype<value_type> BidiIterator;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   246
   typedef global_regex_namespace::sub_match<BidiIterator> sub_match_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   247
   typedef global_regex_namespace::match_results<BidiIterator> match_results_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   248
   typedef output_iterator_archetype<value_type> OutIterator;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   249
   typedef typename regex_traits_computer<Regex>::type traits_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   250
   typedef global_regex_namespace::regex_iterator<BidiIterator, value_type, traits_type> regex_iterator_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   251
   typedef global_regex_namespace::regex_token_iterator<BidiIterator, value_type, traits_type> regex_token_iterator_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   252
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   253
   void global_constraints()
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   254
   {
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   255
      //
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   256
      // test non-template components:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   257
      //
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   258
      function_requires<BitmaskConcept<global_regex_namespace::regex_constants::syntax_option_type> >();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   259
      global_regex_namespace::regex_constants::syntax_option_type opts
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   260
         = global_regex_namespace::regex_constants::icase
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   261
         | global_regex_namespace::regex_constants::nosubs
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   262
         | global_regex_namespace::regex_constants::optimize
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   263
         | global_regex_namespace::regex_constants::collate
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   264
         | global_regex_namespace::regex_constants::ECMAScript
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   265
         | global_regex_namespace::regex_constants::basic
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   266
         | global_regex_namespace::regex_constants::extended
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   267
         | global_regex_namespace::regex_constants::awk
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   268
         | global_regex_namespace::regex_constants::grep
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   269
         | global_regex_namespace::regex_constants::egrep;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   270
      ignore_unused_variable_warning(opts);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   271
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   272
      function_requires<BitmaskConcept<global_regex_namespace::regex_constants::match_flag_type> >();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   273
      global_regex_namespace::regex_constants::match_flag_type mopts
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   274
         = global_regex_namespace::regex_constants::match_default
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   275
         | global_regex_namespace::regex_constants::match_not_bol
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   276
         | global_regex_namespace::regex_constants::match_not_eol
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   277
         | global_regex_namespace::regex_constants::match_not_bow
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   278
         | global_regex_namespace::regex_constants::match_not_eow
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   279
         | global_regex_namespace::regex_constants::match_any
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   280
         | global_regex_namespace::regex_constants::match_not_null
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   281
         | global_regex_namespace::regex_constants::match_continuous
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   282
         | global_regex_namespace::regex_constants::match_prev_avail
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   283
         | global_regex_namespace::regex_constants::format_default
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   284
         | global_regex_namespace::regex_constants::format_sed
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   285
         | global_regex_namespace::regex_constants::format_no_copy
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   286
         | global_regex_namespace::regex_constants::format_first_only;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   287
      ignore_unused_variable_warning(mopts);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   288
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   289
      BOOST_STATIC_ASSERT((::boost::is_enum<global_regex_namespace::regex_constants::error_type>::value));
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   290
      global_regex_namespace::regex_constants::error_type e1 = global_regex_namespace::regex_constants::error_collate;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   291
      ignore_unused_variable_warning(e1);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   292
      e1 = global_regex_namespace::regex_constants::error_ctype;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   293
      ignore_unused_variable_warning(e1);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   294
      e1 = global_regex_namespace::regex_constants::error_escape;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   295
      ignore_unused_variable_warning(e1);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   296
      e1 = global_regex_namespace::regex_constants::error_backref;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   297
      ignore_unused_variable_warning(e1);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   298
      e1 = global_regex_namespace::regex_constants::error_brack;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   299
      ignore_unused_variable_warning(e1);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   300
      e1 = global_regex_namespace::regex_constants::error_paren;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   301
      ignore_unused_variable_warning(e1);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   302
      e1 = global_regex_namespace::regex_constants::error_brace;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   303
      ignore_unused_variable_warning(e1);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   304
      e1 = global_regex_namespace::regex_constants::error_badbrace;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   305
      ignore_unused_variable_warning(e1);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   306
      e1 = global_regex_namespace::regex_constants::error_range;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   307
      ignore_unused_variable_warning(e1);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   308
      e1 = global_regex_namespace::regex_constants::error_space;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   309
      ignore_unused_variable_warning(e1);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   310
      e1 = global_regex_namespace::regex_constants::error_badrepeat;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   311
      ignore_unused_variable_warning(e1);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   312
      e1 = global_regex_namespace::regex_constants::error_complexity;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   313
      ignore_unused_variable_warning(e1);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   314
      e1 = global_regex_namespace::regex_constants::error_stack;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   315
      ignore_unused_variable_warning(e1);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   316
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   317
      BOOST_STATIC_ASSERT((::boost::is_base_and_derived<std::runtime_error, global_regex_namespace::regex_error>::value  ));
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   318
      const global_regex_namespace::regex_error except(e1);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   319
      e1 = except.code();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   320
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   321
      typedef typename Regex::value_type value_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   322
      function_requires< RegexTraitsConcept<global_regex_namespace::regex_traits<char> > >();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   323
      function_requires< BaseRegexConcept<global_regex_namespace::basic_regex<char> > >();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   324
   }
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   325
   void constraints() 
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   326
   {
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   327
      global_constraints();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   328
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   329
      BOOST_STATIC_ASSERT((::boost::is_same< flag_type, global_regex_namespace::regex_constants::syntax_option_type>::value));
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   330
      flag_type opts
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   331
         = Regex::icase
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   332
         | Regex::nosubs
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   333
         | Regex::optimize
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   334
         | Regex::collate
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   335
         | Regex::ECMAScript
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   336
         | Regex::basic
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   337
         | Regex::extended
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   338
         | Regex::awk
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   339
         | Regex::grep
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   340
         | Regex::egrep;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   341
      ignore_unused_variable_warning(opts);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   342
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   343
      function_requires<DefaultConstructibleConcept<Regex> >();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   344
      function_requires<CopyConstructibleConcept<Regex> >();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   345
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   346
      // Regex constructors:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   347
      Regex e1(m_pointer);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   348
      ignore_unused_variable_warning(e1);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   349
      Regex e2(m_pointer, m_flags);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   350
      ignore_unused_variable_warning(e2);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   351
      Regex e3(m_pointer, m_size, m_flags);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   352
      ignore_unused_variable_warning(e3);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   353
      Regex e4(in1, in2);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   354
      ignore_unused_variable_warning(e4);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   355
      Regex e5(in1, in2, m_flags);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   356
      ignore_unused_variable_warning(e5);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   357
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   358
      // assign etc:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   359
      Regex e;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   360
      e = m_pointer;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   361
      e = e1;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   362
      e.assign(e1);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   363
      e.assign(m_pointer);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   364
      e.assign(m_pointer, m_flags);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   365
      e.assign(m_pointer, m_size, m_flags);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   366
      e.assign(in1, in2);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   367
      e.assign(in1, in2, m_flags);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   368
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   369
      // access:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   370
      const Regex ce;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   371
      unsigned i = ce.mark_count();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   372
      ignore_unused_variable_warning(i);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   373
      m_flags = ce.flags();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   374
      e.imbue(ce.getloc());
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   375
      e.swap(e1);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   376
      
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   377
      global_regex_namespace::swap(e, e1);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   378
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   379
      // sub_match:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   380
      BOOST_STATIC_ASSERT((::boost::is_base_and_derived<std::pair<BidiIterator, BidiIterator>, sub_match_type>::value));
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   381
      typedef typename sub_match_type::value_type sub_value_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   382
      typedef typename sub_match_type::difference_type sub_diff_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   383
      typedef typename sub_match_type::iterator sub_iter_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   384
      BOOST_STATIC_ASSERT((::boost::is_same<sub_value_type, value_type>::value));
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   385
      BOOST_STATIC_ASSERT((::boost::is_same<sub_iter_type, BidiIterator>::value));
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   386
      bool b = m_sub.matched;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   387
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   388
      BidiIterator bi = m_sub.first;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   389
      ignore_unused_variable_warning(bi);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   390
      bi = m_sub.second;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   391
      ignore_unused_variable_warning(bi);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   392
      sub_diff_type diff = m_sub.length();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   393
      ignore_unused_variable_warning(diff);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   394
      // match_results tests:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   395
      typedef typename match_results_type::value_type mr_value_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   396
      typedef typename match_results_type::const_reference mr_const_reference;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   397
      typedef typename match_results_type::reference mr_reference;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   398
      typedef typename match_results_type::const_iterator mr_const_iterator;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   399
      typedef typename match_results_type::iterator mr_iterator;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   400
      typedef typename match_results_type::difference_type mr_difference_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   401
      typedef typename match_results_type::size_type mr_size_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   402
      typedef typename match_results_type::allocator_type mr_allocator_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   403
      typedef typename match_results_type::char_type mr_char_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   404
      typedef typename match_results_type::string_type mr_string_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   405
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   406
      match_results_type m1;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   407
      mr_allocator_type at;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   408
      match_results_type m2(at);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   409
      match_results_type m3(m1);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   410
      m1 = m2;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   411
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   412
      int ival = 0;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   413
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   414
      mr_size_type mrs = m_cresults.size();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   415
      ignore_unused_variable_warning(mrs);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   416
      mrs = m_cresults.max_size();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   417
      ignore_unused_variable_warning(mrs);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   418
      b = m_cresults.empty();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   419
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   420
      mr_difference_type mrd = m_cresults.length();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   421
      ignore_unused_variable_warning(mrd);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   422
      mrd = m_cresults.length(ival);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   423
      ignore_unused_variable_warning(mrd);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   424
      mrd = m_cresults.position();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   425
      ignore_unused_variable_warning(mrd);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   426
      mrd = m_cresults.position(mrs);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   427
      ignore_unused_variable_warning(mrd);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   428
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   429
      mr_const_reference mrcr = m_cresults[ival];
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   430
      ignore_unused_variable_warning(mrcr);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   431
      mr_const_reference mrcr2 = m_cresults.prefix();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   432
      ignore_unused_variable_warning(mrcr2);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   433
      mr_const_reference mrcr3 = m_cresults.suffix();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   434
      ignore_unused_variable_warning(mrcr3);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   435
      mr_const_iterator mrci = m_cresults.begin();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   436
      ignore_unused_variable_warning(mrci);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   437
      mrci = m_cresults.end();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   438
      ignore_unused_variable_warning(mrci);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   439
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   440
      mr_allocator_type at2 = m_cresults.get_allocator();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   441
      m_results.swap(m_results);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   442
      global_regex_namespace::swap(m_results, m_results);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   443
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   444
      // regex_match:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   445
      b = global_regex_namespace::regex_match(m_in, m_in, m_results, e);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   446
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   447
      b = global_regex_namespace::regex_match(m_in, m_in, m_results, e, m_mft);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   448
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   449
      b = global_regex_namespace::regex_match(m_in, m_in, e);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   450
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   451
      b = global_regex_namespace::regex_match(m_in, m_in, e, m_mft);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   452
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   453
      b = global_regex_namespace::regex_match(m_pointer, m_pmatch, e);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   454
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   455
      b = global_regex_namespace::regex_match(m_pointer, m_pmatch, e, m_mft);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   456
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   457
      b = global_regex_namespace::regex_match(m_pointer, e);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   458
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   459
      b = global_regex_namespace::regex_match(m_pointer, e, m_mft);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   460
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   461
      // regex_search:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   462
      b = global_regex_namespace::regex_search(m_in, m_in, m_results, e);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   463
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   464
      b = global_regex_namespace::regex_search(m_in, m_in, m_results, e, m_mft);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   465
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   466
      b = global_regex_namespace::regex_search(m_in, m_in, e);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   467
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   468
      b = global_regex_namespace::regex_search(m_in, m_in, e, m_mft);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   469
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   470
      b = global_regex_namespace::regex_search(m_pointer, m_pmatch, e);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   471
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   472
      b = global_regex_namespace::regex_search(m_pointer, m_pmatch, e, m_mft);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   473
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   474
      b = global_regex_namespace::regex_search(m_pointer, e);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   475
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   476
      b = global_regex_namespace::regex_search(m_pointer, e, m_mft);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   477
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   478
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   479
      // regex_iterator:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   480
      typedef typename regex_iterator_type::regex_type rit_regex_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   481
      typedef typename regex_iterator_type::value_type rit_value_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   482
      typedef typename regex_iterator_type::difference_type rit_difference_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   483
      typedef typename regex_iterator_type::pointer rit_pointer;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   484
      typedef typename regex_iterator_type::reference rit_reference;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   485
      typedef typename regex_iterator_type::iterator_category rit_iterator_category;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   486
      BOOST_STATIC_ASSERT((::boost::is_same<rit_regex_type, Regex>::value));
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   487
      BOOST_STATIC_ASSERT((::boost::is_same<rit_value_type, match_results_type>::value));
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   488
      BOOST_STATIC_ASSERT((::boost::is_same<rit_difference_type, std::ptrdiff_t>::value));
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   489
      BOOST_STATIC_ASSERT((::boost::is_same<rit_pointer, const match_results_type*>::value));
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   490
      BOOST_STATIC_ASSERT((::boost::is_same<rit_reference, const match_results_type&>::value));
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   491
      BOOST_STATIC_ASSERT((::boost::is_convertible<rit_iterator_category*, std::forward_iterator_tag*>::value));
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   492
      // this takes care of most of the checks needed:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   493
      function_requires<ForwardIteratorConcept<regex_iterator_type> >();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   494
      regex_iterator_type iter1(m_in, m_in, e);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   495
      ignore_unused_variable_warning(iter1);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   496
      regex_iterator_type iter2(m_in, m_in, e, m_mft);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   497
      ignore_unused_variable_warning(iter2);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   498
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   499
      // regex_token_iterator:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   500
      typedef typename regex_token_iterator_type::regex_type rtit_regex_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   501
      typedef typename regex_token_iterator_type::value_type rtit_value_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   502
      typedef typename regex_token_iterator_type::difference_type rtit_difference_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   503
      typedef typename regex_token_iterator_type::pointer rtit_pointer;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   504
      typedef typename regex_token_iterator_type::reference rtit_reference;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   505
      typedef typename regex_token_iterator_type::iterator_category rtit_iterator_category;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   506
      BOOST_STATIC_ASSERT((::boost::is_same<rtit_regex_type, Regex>::value));
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   507
      BOOST_STATIC_ASSERT((::boost::is_same<rtit_value_type, sub_match_type>::value));
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   508
      BOOST_STATIC_ASSERT((::boost::is_same<rtit_difference_type, std::ptrdiff_t>::value));
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   509
      BOOST_STATIC_ASSERT((::boost::is_same<rtit_pointer, const sub_match_type*>::value));
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   510
      BOOST_STATIC_ASSERT((::boost::is_same<rtit_reference, const sub_match_type&>::value));
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   511
      BOOST_STATIC_ASSERT((::boost::is_convertible<rtit_iterator_category*, std::forward_iterator_tag*>::value));
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   512
      // this takes care of most of the checks needed:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   513
      function_requires<ForwardIteratorConcept<regex_token_iterator_type> >();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   514
      regex_token_iterator_type ti1(m_in, m_in, e);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   515
      ignore_unused_variable_warning(ti1);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   516
      regex_token_iterator_type ti2(m_in, m_in, e, 0);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   517
      ignore_unused_variable_warning(ti2);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   518
      regex_token_iterator_type ti3(m_in, m_in, e, 0, m_mft);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   519
      ignore_unused_variable_warning(ti3);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   520
      std::vector<int> subs;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   521
      regex_token_iterator_type ti4(m_in, m_in, e, subs);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   522
      ignore_unused_variable_warning(ti4);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   523
      regex_token_iterator_type ti5(m_in, m_in, e, subs, m_mft);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   524
      ignore_unused_variable_warning(ti5);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   525
      static const int i_array[3] = { 1, 2, 3, };
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   526
      regex_token_iterator_type ti6(m_in, m_in, e, i_array);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   527
      ignore_unused_variable_warning(ti6);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   528
      regex_token_iterator_type ti7(m_in, m_in, e, i_array, m_mft);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   529
      ignore_unused_variable_warning(ti7);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   530
   }
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   531
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   532
   pointer_type m_pointer;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   533
   flag_type m_flags;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   534
   std::size_t m_size;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   535
   input_iterator_type in1, in2;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   536
   const sub_match_type m_sub;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   537
   const value_type m_char;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   538
   match_results_type m_results;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   539
   const match_results_type m_cresults;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   540
   OutIterator m_out;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   541
   BidiIterator m_in;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   542
   global_regex_namespace::regex_constants::match_flag_type m_mft;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   543
   global_regex_namespace::match_results<pointer_type> m_pmatch;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   544
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   545
   BaseRegexConcept();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   546
   BaseRegexConcept(const BaseRegexConcept&);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   547
   BaseRegexConcept& operator=(const BaseRegexConcept&);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   548
};
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   549
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   550
//
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   551
// RegexConcept:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   552
// Test every interface in the std:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   553
//
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   554
template <class Regex>
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   555
struct RegexConcept
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   556
{
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   557
   typedef typename Regex::value_type value_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   558
   //typedef typename Regex::size_type size_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   559
   typedef typename Regex::flag_type flag_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   560
   typedef typename Regex::locale_type locale_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   561
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   562
   // derived test types:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   563
   typedef const value_type* pointer_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   564
   typedef std::basic_string<value_type> string_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   565
   typedef boost::bidirectional_iterator_archetype<value_type> BidiIterator;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   566
   typedef global_regex_namespace::sub_match<BidiIterator> sub_match_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   567
   typedef global_regex_namespace::match_results<BidiIterator> match_results_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   568
   typedef output_iterator_archetype<value_type> OutIterator;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   569
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   570
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   571
   void constraints() 
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   572
   {
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   573
      function_requires<BaseRegexConcept<Regex> >();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   574
      // string based construct:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   575
      Regex e1(m_string);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   576
      ignore_unused_variable_warning(e1);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   577
      Regex e2(m_string, m_flags);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   578
      ignore_unused_variable_warning(e2);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   579
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   580
      // assign etc:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   581
      Regex e;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   582
      e = m_string;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   583
      e.assign(m_string);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   584
      e.assign(m_string, m_flags);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   585
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   586
      // sub_match:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   587
      string_type s(m_sub);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   588
      ignore_unused_variable_warning(s);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   589
      s = m_sub.str();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   590
      ignore_unused_variable_warning(s);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   591
      int i = m_sub.compare(m_string);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   592
      ignore_unused_variable_warning(i);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   593
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   594
      int i2 = m_sub.compare(m_sub);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   595
      ignore_unused_variable_warning(i2);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   596
      i2 = m_sub.compare(m_pointer);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   597
      ignore_unused_variable_warning(i2);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   598
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   599
      bool b = m_sub == m_sub;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   600
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   601
      b = m_sub != m_sub;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   602
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   603
      b = m_sub <= m_sub;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   604
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   605
      b = m_sub <= m_sub;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   606
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   607
      b = m_sub > m_sub;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   608
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   609
      b = m_sub >= m_sub;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   610
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   611
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   612
      b = m_sub == m_pointer;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   613
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   614
      b = m_sub != m_pointer;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   615
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   616
      b = m_sub <= m_pointer;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   617
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   618
      b = m_sub <= m_pointer;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   619
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   620
      b = m_sub > m_pointer;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   621
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   622
      b = m_sub >= m_pointer;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   623
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   624
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   625
      b = m_pointer == m_sub;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   626
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   627
      b = m_pointer != m_sub;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   628
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   629
      b = m_pointer <= m_sub;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   630
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   631
      b = m_pointer <= m_sub;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   632
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   633
      b = m_pointer > m_sub;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   634
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   635
      b = m_pointer >= m_sub;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   636
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   637
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   638
      b = m_sub == m_char;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   639
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   640
      b = m_sub != m_char;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   641
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   642
      b = m_sub <= m_char;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   643
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   644
      b = m_sub <= m_char;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   645
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   646
      b = m_sub > m_char;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   647
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   648
      b = m_sub >= m_char;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   649
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   650
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   651
      b = m_char == m_sub;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   652
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   653
      b = m_char != m_sub;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   654
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   655
      b = m_char <= m_sub;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   656
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   657
      b = m_char <= m_sub;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   658
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   659
      b = m_char > m_sub;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   660
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   661
      b = m_char >= m_sub;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   662
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   663
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   664
      b = m_sub == m_string;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   665
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   666
      b = m_sub != m_string;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   667
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   668
      b = m_sub <= m_string;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   669
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   670
      b = m_sub <= m_string;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   671
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   672
      b = m_sub > m_string;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   673
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   674
      b = m_sub >= m_string;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   675
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   676
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   677
      b = m_string == m_sub;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   678
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   679
      b = m_string != m_sub;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   680
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   681
      b = m_string <= m_sub;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   682
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   683
      b = m_string <= m_sub;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   684
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   685
      b = m_string > m_sub;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   686
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   687
      b = m_string >= m_sub;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   688
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   689
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   690
      // match results:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   691
      m_string = m_results.str();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   692
      ignore_unused_variable_warning(m_string);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   693
      m_string = m_results.str(0);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   694
      ignore_unused_variable_warning(m_string);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   695
      m_out = m_cresults.format(m_out, m_string);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   696
      m_out = m_cresults.format(m_out, m_string, m_mft);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   697
      m_string = m_cresults.format(m_string);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   698
      ignore_unused_variable_warning(m_string);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   699
      m_string = m_cresults.format(m_string, m_mft);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   700
      ignore_unused_variable_warning(m_string);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   701
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   702
      // regex_match:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   703
      b = global_regex_namespace::regex_match(m_string, m_smatch, e);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   704
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   705
      b = global_regex_namespace::regex_match(m_string, m_smatch, e, m_mft);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   706
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   707
      b = global_regex_namespace::regex_match(m_string, e);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   708
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   709
      b = global_regex_namespace::regex_match(m_string, e, m_mft);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   710
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   711
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   712
      // regex_search:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   713
      b = global_regex_namespace::regex_search(m_string, m_smatch, e);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   714
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   715
      b = global_regex_namespace::regex_search(m_string, m_smatch, e, m_mft);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   716
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   717
      b = global_regex_namespace::regex_search(m_string, e);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   718
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   719
      b = global_regex_namespace::regex_search(m_string, e, m_mft);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   720
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   721
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   722
      // regex_replace:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   723
      m_out = global_regex_namespace::regex_replace(m_out, m_in, m_in, e, m_string, m_mft);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   724
      m_out = global_regex_namespace::regex_replace(m_out, m_in, m_in, e, m_string);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   725
      m_string = global_regex_namespace::regex_replace(m_string, e, m_string, m_mft);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   726
      ignore_unused_variable_warning(m_string);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   727
      m_string = global_regex_namespace::regex_replace(m_string, e, m_string);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   728
      ignore_unused_variable_warning(m_string);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   729
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   730
   }
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   731
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   732
   flag_type m_flags;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   733
   string_type m_string;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   734
   const sub_match_type m_sub;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   735
   match_results_type m_results;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   736
   pointer_type m_pointer;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   737
   value_type m_char;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   738
   const match_results_type m_cresults;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   739
   OutIterator m_out;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   740
   BidiIterator m_in;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   741
   global_regex_namespace::regex_constants::match_flag_type m_mft;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   742
   global_regex_namespace::match_results<typename string_type::const_iterator> m_smatch;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   743
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   744
   RegexConcept();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   745
   RegexConcept(const RegexConcept&);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   746
   RegexConcept& operator=(const RegexConcept&);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   747
};
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   748
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   749
#ifndef BOOST_REGEX_TEST_STD
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   750
//
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   751
// BoostRegexConcept:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   752
// Test every interface in the Boost implementation:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   753
//
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   754
template <class Regex>
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   755
struct BoostRegexConcept
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   756
{
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   757
   typedef typename Regex::value_type value_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   758
   typedef typename Regex::size_type size_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   759
   typedef typename Regex::flag_type flag_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   760
   typedef typename Regex::locale_type locale_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   761
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   762
   // derived test types:
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   763
   typedef const value_type* pointer_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   764
   typedef std::basic_string<value_type> string_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   765
   typedef typename Regex::const_iterator const_iterator;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   766
   typedef bidirectional_iterator_archetype<value_type> BidiIterator;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   767
   typedef global_regex_namespace::sub_match<BidiIterator> sub_match_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   768
   typedef global_regex_namespace::match_results<BidiIterator> match_results_type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   769
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   770
   void constraints() 
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   771
   {
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   772
      global_regex_namespace::regex_constants::match_flag_type mopts
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   773
         = global_regex_namespace::regex_constants::match_default
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   774
         | global_regex_namespace::regex_constants::match_not_bol
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   775
         | global_regex_namespace::regex_constants::match_not_eol
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   776
         | global_regex_namespace::regex_constants::match_not_bow
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   777
         | global_regex_namespace::regex_constants::match_not_eow
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   778
         | global_regex_namespace::regex_constants::match_any
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   779
         | global_regex_namespace::regex_constants::match_not_null
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   780
         | global_regex_namespace::regex_constants::match_continuous
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   781
         | global_regex_namespace::regex_constants::match_partial
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   782
         | global_regex_namespace::regex_constants::match_prev_avail
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   783
         | global_regex_namespace::regex_constants::format_default
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   784
         | global_regex_namespace::regex_constants::format_sed
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   785
         | global_regex_namespace::regex_constants::format_perl
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   786
         | global_regex_namespace::regex_constants::format_no_copy
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   787
         | global_regex_namespace::regex_constants::format_first_only;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   788
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   789
      (void)mopts;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   790
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   791
      function_requires<RegexConcept<Regex> >();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   792
      const global_regex_namespace::regex_error except(global_regex_namespace::regex_constants::error_collate);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   793
      std::ptrdiff_t pt = except.position();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   794
      ignore_unused_variable_warning(pt);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   795
      const Regex ce, ce2;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   796
#ifndef BOOST_NO_STD_LOCALE
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   797
      m_stream << ce;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   798
#endif
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   799
      unsigned i = ce.error_code();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   800
      ignore_unused_variable_warning(i);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   801
      pointer_type p = ce.expression();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   802
      ignore_unused_variable_warning(p);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   803
      int i2 = ce.compare(ce2);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   804
      ignore_unused_variable_warning(i2);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   805
      bool b = ce == ce2;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   806
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   807
      b = ce.empty();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   808
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   809
      b = ce != ce2;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   810
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   811
      b = ce < ce2;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   812
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   813
      b = ce > ce2;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   814
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   815
      b = ce <= ce2;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   816
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   817
      b = ce >= ce2;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   818
      ignore_unused_variable_warning(b);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   819
      i = ce.status();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   820
      ignore_unused_variable_warning(i);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   821
      size_type s = ce.max_size();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   822
      ignore_unused_variable_warning(s);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   823
      s = ce.size();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   824
      ignore_unused_variable_warning(s);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   825
      const_iterator pi = ce.begin();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   826
      ignore_unused_variable_warning(pi);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   827
      pi = ce.end();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   828
      ignore_unused_variable_warning(pi);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   829
      string_type s2 = ce.str();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   830
      ignore_unused_variable_warning(s2);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   831
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   832
      m_string = m_sub + m_sub;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   833
      ignore_unused_variable_warning(m_string);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   834
      m_string = m_sub + m_pointer;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   835
      ignore_unused_variable_warning(m_string);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   836
      m_string = m_pointer + m_sub;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   837
      ignore_unused_variable_warning(m_string);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   838
      m_string = m_sub + m_string;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   839
      ignore_unused_variable_warning(m_string);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   840
      m_string = m_string + m_sub;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   841
      ignore_unused_variable_warning(m_string);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   842
      m_string = m_sub + m_char;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   843
      ignore_unused_variable_warning(m_string);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   844
      m_string = m_char + m_sub;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   845
      ignore_unused_variable_warning(m_string);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   846
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   847
#ifndef BOOST_NO_STD_LOCALE
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   848
      m_stream << m_sub;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   849
      m_stream << m_cresults;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   850
#endif
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   851
   }
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   852
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   853
   std::basic_ostream<value_type> m_stream;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   854
   sub_match_type m_sub;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   855
   pointer_type m_pointer;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   856
   string_type m_string;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   857
   const value_type m_char;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   858
   match_results_type m_results;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   859
   const match_results_type m_cresults;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   860
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   861
   BoostRegexConcept();
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   862
   BoostRegexConcept(const BoostRegexConcept&);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   863
   BoostRegexConcept& operator=(const BoostRegexConcept&);
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   864
};
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   865
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   866
#endif // BOOST_REGEX_TEST_STD
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   867
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   868
}
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   869
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
   870
#endif