#ifdef DEBUG
# ifdef DEAL_II_HAVE_BUILTIN_EXPECT
# define Assert(cond, exc) \
-{ \
- if (__builtin_expect(!(cond), false)) \
- ::dealii::deal_II_exceptions::internals:: issue_error_noreturn( \
- ::dealii::deal_II_exceptions::internals::abort_on_exception, \
- __FILE__, __LINE__, __PRETTY_FUNCTION__, #cond, #exc, exc); \
-}
+ { \
+ if (__builtin_expect(!(cond), false)) \
+ ::dealii::deal_II_exceptions::internals:: issue_error_noreturn( \
+ ::dealii::deal_II_exceptions::internals::abort_on_exception, \
+ __FILE__, __LINE__, __PRETTY_FUNCTION__, #cond, #exc, exc); \
+ }
# else /*ifdef DEAL_II_HAVE_BUILTIN_EXPECT*/
# define Assert(cond, exc) \
-{ \
- if (!(cond)) \
- ::dealii::deal_II_exceptions::internals:: issue_error_noreturn( \
- ::dealii::deal_II_exceptions::internals::abort_on_exception, \
- __FILE__, __LINE__, __PRETTY_FUNCTION__, #cond, #exc, exc); \
-}
+ { \
+ if (!(cond)) \
+ ::dealii::deal_II_exceptions::internals:: issue_error_noreturn( \
+ ::dealii::deal_II_exceptions::internals::abort_on_exception, \
+ __FILE__, __LINE__, __PRETTY_FUNCTION__, #cond, #exc, exc); \
+ }
# endif /*ifdef DEAL_II_HAVE_BUILTIN_EXPECT*/
#else
#define Assert(cond, exc) \
#ifdef DEBUG
# ifdef DEAL_II_HAVE_BUILTIN_EXPECT
# define AssertNothrow(cond, exc) \
-{ \
- if (__builtin_expect(!(cond), false)) \
- ::dealii::deal_II_exceptions::internals::issue_error_nothrow( \
- ::dealii::deal_II_exceptions::internals::abort_nothrow_on_exception, \
- __FILE__, __LINE__, __PRETTY_FUNCTION__, #cond, #exc, exc); \
-}
+ { \
+ if (__builtin_expect(!(cond), false)) \
+ ::dealii::deal_II_exceptions::internals::issue_error_nothrow( \
+ ::dealii::deal_II_exceptions::internals::abort_nothrow_on_exception, \
+ __FILE__, __LINE__, __PRETTY_FUNCTION__, #cond, #exc, exc); \
+ }
# else /*ifdef DEAL_II_HAVE_BUILTIN_EXPECT*/
# define AssertNothrow(cond, exc) \
-{ \
- if (!(cond)) \
- ::dealii::deal_II_exceptions::internals::issue_error_nothrow( \
- ::dealii::deal_II_exceptions::internals::abort_nothrow_on_exception, \
- __FILE__, __LINE__, __PRETTY_FUNCTION__, #cond, #exc, exc); \
-}
+ { \
+ if (!(cond)) \
+ ::dealii::deal_II_exceptions::internals::issue_error_nothrow( \
+ ::dealii::deal_II_exceptions::internals::abort_nothrow_on_exception, \
+ __FILE__, __LINE__, __PRETTY_FUNCTION__, #cond, #exc, exc); \
+ }
# endif /*ifdef DEAL_II_HAVE_BUILTIN_EXPECT*/
#else
#define AssertNothrow(cond, exc) \
*/
#ifdef DEAL_II_HAVE_BUILTIN_EXPECT
#define AssertThrow(cond, exc) \
-{ \
- if (__builtin_expect(!(cond), false)) \
- ::dealii::deal_II_exceptions::internals:: issue_error_noreturn( \
- ::dealii::deal_II_exceptions::internals::throw_on_exception, \
- __FILE__, __LINE__, __PRETTY_FUNCTION__, #cond, #exc, exc); \
-}
+ { \
+ if (__builtin_expect(!(cond), false)) \
+ ::dealii::deal_II_exceptions::internals:: issue_error_noreturn( \
+ ::dealii::deal_II_exceptions::internals::throw_on_exception, \
+ __FILE__, __LINE__, __PRETTY_FUNCTION__, #cond, #exc, exc); \
+ }
#else /*ifdef DEAL_II_HAVE_BUILTIN_EXPECT*/
#define AssertThrow(cond, exc) \
-{ \
- if (!(cond)) \
- ::dealii::deal_II_exceptions::internals::issue_error_noreturn( \
- ::dealii::deal_II_exceptions::internals::throw_on_exception, \
- __FILE__, __LINE__, __PRETTY_FUNCTION__, #cond, #exc, exc); \
-}
+ { \
+ if (!(cond)) \
+ ::dealii::deal_II_exceptions::internals::issue_error_noreturn( \
+ ::dealii::deal_II_exceptions::internals::throw_on_exception, \
+ __FILE__, __LINE__, __PRETTY_FUNCTION__, #cond, #exc, exc); \
+ }
#endif /*ifdef DEAL_II_HAVE_BUILTIN_EXPECT*/
/**
* @author Guido Kanschat 2007
*/
#define AssertDimension(dim1,dim2) \
-Assert((dim1) == (dim2), dealii::ExcDimensionMismatch((dim1),(dim2)))
+ Assert((dim1) == (dim2), dealii::ExcDimensionMismatch((dim1),(dim2)))
/**
* @ingroup Exceptions
* @author Guido Kanschat 2010
*/
-#define AssertVectorVectorDimension(vec,dim1,dim2) \
-AssertDimension((vec).size(), (dim1)); \
-for (unsigned int i=0;i<dim1;++i) {AssertDimension((vec)[i].size(), (dim2));} \
+#define AssertVectorVectorDimension(vec,dim1,dim2) \
+ AssertDimension((vec).size(), (dim1)); \
+ for (unsigned int i=0;i<dim1;++i) {AssertDimension((vec)[i].size(), (dim2));}
namespace internal
{
* @author Guido Kanschat 2007
*/
#define AssertIndexRange(index,range) \
-Assert((index) < (range), \
-dealii::ExcIndexRangeType<typename ::dealii::internal::argument_type< \
-void(typename std::common_type<decltype(index), \
- decltype(range)>::type)>::type>((index),0,(range)))
+ Assert((index) < (range), \
+ dealii::ExcIndexRangeType<typename ::dealii::internal::argument_type< \
+ void(typename std::common_type<decltype(index), \
+ decltype(range)>::type)>::type>((index),0,(range)))
/**
* An assertion that checks whether a number is finite or not. We explicitly
* @author Wolfgang Bangerth, 2015
*/
#define AssertIsFinite(number) \
-Assert(dealii::numbers::is_finite(number), \
-dealii::ExcNumberNotFinite(std::complex<double>(number)))
+ Assert(dealii::numbers::is_finite(number), \
+ dealii::ExcNumberNotFinite(std::complex<double>(number)))
#ifdef DEAL_II_WITH_MPI
/**
* @author David Wells, 2016
*/
#define AssertThrowMPI(error_code) \
-AssertThrow(error_code == MPI_SUCCESS, dealii::ExcMPI(error_code))
+ AssertThrow(error_code == MPI_SUCCESS, dealii::ExcMPI(error_code))
#else
#define AssertThrowMPI(error_code) {}
#endif // DEAL_II_WITH_MPI