forked from boostorg/regex
Add testing of standalone mode.
Allow tests to be built in standalone mode. Update CI. Update docs.
This commit is contained in:
@ -16,14 +16,6 @@
|
||||
* DESCRIPTION: main regex test declarations.
|
||||
*/
|
||||
|
||||
#include <boost/detail/workaround.hpp>
|
||||
|
||||
#if BOOST_WORKAROUND(BOOST_BORLANDC, < 0x560)
|
||||
// we get unresolved externals from basic_string
|
||||
// unless we do this, a well known Borland bug:
|
||||
#define _RWSTD_COMPILE_INSTANTIATE
|
||||
#endif
|
||||
|
||||
#include "test.hpp"
|
||||
|
||||
#ifdef BOOST_MSVC
|
||||
|
@ -217,6 +217,13 @@ int main(int argc, char * argv[])
|
||||
return cpp_main(argc, argv);
|
||||
}
|
||||
|
||||
#elif defined(BOOST_REGEX_STANDALONE)
|
||||
|
||||
int main(int argc, char* argv[])
|
||||
{
|
||||
return cpp_main(argc, argv);
|
||||
}
|
||||
|
||||
#else
|
||||
|
||||
#include <boost/detail/lightweight_main.hpp>
|
||||
|
@ -27,6 +27,23 @@
|
||||
#pragma warning(disable:1418 981 383 1419 7)
|
||||
#endif
|
||||
|
||||
#ifndef BOOST_WORKAROUND
|
||||
#define BOOST_WORKAROUND(x, y) false
|
||||
#endif
|
||||
#ifdef BOOST_REGEX_STANDALONE
|
||||
#include <cstdint>
|
||||
|
||||
namespace boost { using std::uint32_t; }
|
||||
|
||||
#define BOOST_JOIN(X, Y) BOOST_DO_JOIN(X, Y)
|
||||
#define BOOST_DO_JOIN(X, Y) BOOST_DO_JOIN2(X,Y)
|
||||
#define BOOST_DO_JOIN2(X, Y) X##Y
|
||||
|
||||
#define BOOST_STRINGIZE(X) BOOST_DO_STRINGIZE(X)
|
||||
#define BOOST_DO_STRINGIZE(X) #X
|
||||
|
||||
#endif
|
||||
|
||||
#include <typeinfo>
|
||||
#include "test_not_regex.hpp"
|
||||
#include "test_regex_search.hpp"
|
||||
|
@ -20,10 +20,25 @@
|
||||
// We can only build this if we have ICU support:
|
||||
//
|
||||
#include <boost/regex/config.hpp>
|
||||
|
||||
#ifdef __has_include
|
||||
#if __has_include(<unicode/utypes.h>)
|
||||
#define BOOST_HAS_ICU
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#if defined(BOOST_HAS_ICU) && !defined(BOOST_NO_STD_WSTRING)
|
||||
|
||||
#include <boost/regex/icu.hpp>
|
||||
#ifndef BOOST_REGEX_STANDALONE
|
||||
#include <boost/mpl/int.hpp>
|
||||
#else
|
||||
#include <type_traits>
|
||||
namespace boost { namespace mpl {
|
||||
template <int I>
|
||||
using int_ = ::std::integral_constant<int, I>;
|
||||
} }
|
||||
#endif
|
||||
#include "test.hpp"
|
||||
|
||||
namespace unnecessary_fix{
|
||||
|
@ -19,7 +19,7 @@
|
||||
//
|
||||
// We can only build this if we have ATL support:
|
||||
//
|
||||
#include <boost/config.hpp>
|
||||
#include <boost/regex/config.hpp>
|
||||
|
||||
#ifdef TEST_MFC
|
||||
|
||||
|
Reference in New Issue
Block a user