epoc32/include/stdapis/boost/assert.hpp
author William Roberts <williamr@symbian.org>
Wed, 31 Mar 2010 12:33:34 +0100
branchSymbian3
changeset 4 837f303aceeb
parent 3 e1b950c65cb4
permissions -rw-r--r--
Current Symbian^3 public API header files (from PDK 3.0.h)
This is the epoc32/include tree with the "platform" subtrees removed, and
all but a selected few mbg and rsg files removed.
     1 //
     2 //  boost/assert.hpp - BOOST_ASSERT(expr)
     3 //
     4 //  Copyright (c) 2001, 2002 Peter Dimov and Multi Media Ltd.
     5 //
     6 // Distributed under the Boost Software License, Version 1.0. (See
     7 // accompanying file LICENSE_1_0.txt or copy at
     8 // http://www.boost.org/LICENSE_1_0.txt)
     9 //
    10 //  Note: There are no include guards. This is intentional.
    11 //
    12 //  See http://www.boost.org/libs/utility/assert.html for documentation.
    13 //
    14 
    15 #undef BOOST_ASSERT
    16 
    17 #if defined(BOOST_DISABLE_ASSERTS)
    18 
    19 # define BOOST_ASSERT(expr) ((void)0)
    20 
    21 #elif defined(BOOST_ENABLE_ASSERT_HANDLER)
    22 
    23 #include <boost/current_function.hpp>
    24 
    25 namespace boost
    26 {
    27 
    28 void assertion_failed(char const * expr, char const * function, char const * file, long line); // user defined
    29 
    30 } // namespace boost
    31 
    32 #define BOOST_ASSERT(expr) ((expr)? ((void)0): ::boost::assertion_failed(#expr, BOOST_CURRENT_FUNCTION, __FILE__, __LINE__))
    33 
    34 #else
    35 # include <assert.h> // .h to support old libraries w/o <cassert> - effect is the same
    36 # define BOOST_ASSERT(expr) assert(expr)
    37 #endif