Add throw/catch test for bad_function_call

This commit is contained in:
Peter Dimov
2018-10-19 04:04:06 +03:00
committed by James E. King III
parent 755d3c2001
commit 5b2acbc175
3 changed files with 36 additions and 0 deletions

View File

@ -0,0 +1,17 @@
// Copyright 2018 Peter Dimov.
// Distributed under the Boost Software License, Version 1.0.
#include <boost/function.hpp>
#include <boost/config.hpp>
#if defined(THROW_BAD_FUNCTION_CALL_DYN_LINK)
# define EXPORT BOOST_SYMBOL_EXPORT
#else
# define EXPORT
#endif
EXPORT void throw_bad_function_call()
{
throw boost::bad_function_call();
}