Re: [Boost-bugs] [Boost C++ Libraries] #7028: NDEBUG should disable asserts even if BOOST_ENABLE_ASSERT_HANDLER is defined

Subject: Re: [Boost-bugs] [Boost C++ Libraries] #7028: NDEBUG should disable asserts even if BOOST_ENABLE_ASSERT_HANDLER is defined
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2014-04-14 23:03:25


#7028: NDEBUG should disable asserts even if BOOST_ENABLE_ASSERT_HANDLER is
defined
-------------------------------------+-------------------------------------
  Reporter: mgaunard | Owner: pdimov
      Type: Feature Requests | Status: reopened
 Milestone: To Be Determined | Component: utility
   Version: Boost Development | Severity: Problem
  Trunk | Keywords: BOOST_ASSERT assert
Resolution: | BOOST_ENABLE_ASSERT_HANDLER NDEBUG
-------------------------------------+-------------------------------------

Comment (by chris.cooper@…):

 Replying to [comment:20 chris.cooper@…]:
> I think assert_test.cpp needs changed too?

 Sorry, assert_test.cpp compiles just fine. I'm just confused on your
 intended usage ... in the patched version, line 59 looks like this:
 #if defined(BOOST_DISABLE_ASSERTS) || (
 defined(BOOST_ENABLE_ASSERT_DEBUG_HANDLER) && defined(NDEBUG) )
 so if I'm creating a release build (NDEBUG is defined) and I haven't
 defined BOOST_DISABLE_ASSERTS, then by defining
 BOOST_ENABLE_ASSERT_DEBUG_HANDLER, it disables BOOST_ASSERT_MSG (by
 #defining it to (void)0). So by defining a macro whose name contains
 ENABLE, I am disabling the ASSERT functionality?

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/7028#comment:21>
Boost C++ Libraries <http://www.boost.org/>
Boost provides free peer-reviewed portable C++ source libraries.

This archive was generated by hypermail 2.1.7 : 2017-02-16 18:50:16 UTC