mirror of
https://github.com/boostorg/throw_exception.git
synced 2025-07-12 20:16:33 +02:00
Compare commits
9 Commits
feature/mo
...
boost-1.70
Author | SHA1 | Date | |
---|---|---|---|
37dfb7fe92 | |||
9dfba607d9 | |||
074bc77efb | |||
9d5b953dcf | |||
eafb1c877b | |||
dd7d2a273c | |||
322d7611af | |||
56dd1c4111 | |||
40e067d7b7 |
17
.travis.yml
17
.travis.yml
@ -110,7 +110,7 @@ matrix:
|
||||
|
||||
- os: linux
|
||||
compiler: g++-8
|
||||
env: TOOLSET=gcc COMPILER=g++-8 CXXSTD=03,11,14,17
|
||||
env: TOOLSET=gcc COMPILER=g++-8 CXXSTD=03,11,14,17,2a
|
||||
addons:
|
||||
apt:
|
||||
packages:
|
||||
@ -120,7 +120,7 @@ matrix:
|
||||
|
||||
- os: linux
|
||||
compiler: g++-8
|
||||
env: UBSAN=1 TOOLSET=gcc COMPILER=g++-8 CXXSTD=03,11,14,17 UBSAN_OPTIONS=print_stacktrace=1 LINKFLAGS=-fuse-ld=gold
|
||||
env: UBSAN=1 TOOLSET=gcc COMPILER=g++-8 CXXSTD=03,11,14,17,2a UBSAN_OPTIONS=print_stacktrace=1 LINKFLAGS=-fuse-ld=gold
|
||||
addons:
|
||||
apt:
|
||||
packages:
|
||||
@ -227,6 +227,17 @@ matrix:
|
||||
- ubuntu-toolchain-r-test
|
||||
- llvm-toolchain-trusty-6.0
|
||||
|
||||
- os: linux
|
||||
compiler: clang++-7
|
||||
env: TOOLSET=clang COMPILER=clang++-7 CXXSTD=03,11,14,17,2a
|
||||
addons:
|
||||
apt:
|
||||
packages:
|
||||
- clang-7
|
||||
sources:
|
||||
- ubuntu-toolchain-r-test
|
||||
- llvm-toolchain-trusty-7
|
||||
|
||||
- os: linux
|
||||
compiler: clang++-6.0
|
||||
env: UBSAN=1 TOOLSET=clang COMPILER=clang++-6.0 CXXSTD=03,11,14,17 UBSAN_OPTIONS=print_stacktrace=1
|
||||
@ -263,8 +274,6 @@ install:
|
||||
- cd ..
|
||||
- git clone -b $BOOST_BRANCH --depth 1 https://github.com/boostorg/boost.git boost-root
|
||||
- cd boost-root
|
||||
- git submodule update --init tools/build
|
||||
- git submodule update --init libs/config
|
||||
- git submodule update --init tools/boostdep
|
||||
- cp -r $TRAVIS_BUILD_DIR/* libs/throw_exception
|
||||
- python tools/boostdep/depinst/depinst.py throw_exception
|
||||
|
@ -2,6 +2,9 @@
|
||||
# Distributed under the Boost Software License, Version 1.0.
|
||||
# See accompanying file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt
|
||||
|
||||
# Partial (add_subdirectory only) and experimental CMake support
|
||||
# Subject to change; please do not rely on the contents of this file yet
|
||||
|
||||
cmake_minimum_required(VERSION 3.5)
|
||||
project(BoostThrowException LANGUAGES CXX)
|
||||
|
||||
|
@ -44,10 +44,8 @@ install:
|
||||
- cd ..
|
||||
- git clone -b %BOOST_BRANCH% --depth 1 https://github.com/boostorg/boost.git boost-root
|
||||
- cd boost-root
|
||||
- git submodule update --init tools/build
|
||||
- git submodule update --init libs/config
|
||||
- git submodule update --init tools/boostdep
|
||||
- xcopy /s /e /q %APPVEYOR_BUILD_FOLDER% libs\throw_exception
|
||||
- xcopy /s /e /q %APPVEYOR_BUILD_FOLDER% libs\throw_exception\
|
||||
- python tools/boostdep/depinst/depinst.py throw_exception
|
||||
- cmd /c bootstrap
|
||||
- b2 -d0 headers
|
||||
|
@ -472,6 +472,51 @@ boost
|
||||
{
|
||||
return exception_detail::clone_impl<T>(x);
|
||||
}
|
||||
|
||||
template <class T>
|
||||
struct
|
||||
BOOST_SYMBOL_VISIBLE
|
||||
wrapexcept:
|
||||
public exception_detail::clone_impl<typename exception_detail::enable_error_info_return_type<T>::type>
|
||||
{
|
||||
typedef exception_detail::clone_impl<typename exception_detail::enable_error_info_return_type<T>::type> base_type;
|
||||
public:
|
||||
explicit
|
||||
wrapexcept( typename exception_detail::enable_error_info_return_type<T>::type const & x ):
|
||||
base_type( x )
|
||||
{
|
||||
}
|
||||
|
||||
~wrapexcept() throw()
|
||||
{
|
||||
}
|
||||
};
|
||||
|
||||
namespace
|
||||
exception_detail
|
||||
{
|
||||
template <class T>
|
||||
struct
|
||||
remove_error_info_injector
|
||||
{
|
||||
typedef T type;
|
||||
};
|
||||
|
||||
template <class T>
|
||||
struct
|
||||
remove_error_info_injector< error_info_injector<T> >
|
||||
{
|
||||
typedef T type;
|
||||
};
|
||||
|
||||
template <class T>
|
||||
inline
|
||||
wrapexcept<typename remove_error_info_injector<T>::type>
|
||||
enable_both( T const & x )
|
||||
{
|
||||
return wrapexcept<typename remove_error_info_injector<T>::type>( enable_error_info( x ) );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS)
|
||||
|
@ -67,7 +67,7 @@ template<class E> BOOST_NORETURN inline void throw_exception( E const & e )
|
||||
throw_exception_assert_compatibility(e);
|
||||
|
||||
#ifndef BOOST_EXCEPTION_DISABLE
|
||||
throw enable_current_exception(enable_error_info(e));
|
||||
throw exception_detail::enable_both( e );
|
||||
#else
|
||||
throw e;
|
||||
#endif
|
||||
|
Reference in New Issue
Block a user