Ticket #6451: assert.html.patch
| File assert.html.patch, 3.4 KB (added by , 11 years ago) |
|---|
-
assert.html
37 37 <P>If the macro <STRONG>BOOST_ENABLE_ASSERT_HANDLER</STRONG> is defined when <STRONG><boost/assert.hpp></STRONG> 38 38 is included, <tt>BOOST_ASSERT(expr)</tt> evaluates <b>expr</b> and, if the 39 39 result is false, evaluates the expression</P> 40 <P> <b>BOOST_ASSERT_CURRENT_FUNCTION_NAME</b> defines the macro, used to get current function name. 41 It defaults to <a href="current_function.html">BOOST_CURRENT_FUNCTION</a>. 42 <code>BOOST_CURRENT_FUNCTION</code> can produce very long names, that may lead to huge size of output files. 43 Users may define <b>BOOST_ASSERT_CURRENT_FUNCTION_NAME</b> before including <STRONG><boost/assert.hpp></STRONG> 44 to specify a different current function macro (for example to shorter but not portable __FUNCTION__ macro or to 45 "(unknown)" value). </P> 40 46 <blockquote> 41 <P><tt>::boost::assertion_failed(#expr, <a href="current_function.html">BOOST_CURRENT_FUNCTION</a>,47 <P><tt>::boost::assertion_failed(#expr, BOOST_ASSERT_CURRENT_FUNCTION_NAME, 42 48 __FILE__, __LINE__)</tt></P> 43 49 </blockquote> 44 50 <P><STRONG>assertion_failed</STRONG> is declared in <STRONG><boost/assert.hpp></STRONG> … … 68 74 defined or <code>expr</code> evaluates to <code>true</code>. If those 69 75 macros and <STRONG>BOOST_ENABLE_ASSERT_HANDLER</STRONG> are not 70 76 defined, and <code>expr</code> evaluates to <code>false</code>, an error 71 message that includes <tt>#expr</tt>, <tt>msg</tt>, <tt> <a href="current_function.html">BOOST_CURRENT_FUNCTION</a></tt>, <tt>77 message that includes <tt>#expr</tt>, <tt>msg</tt>, <tt> BOOST_ASSERT_MSG_CURRENT_FUNCTION_NAME </tt>, <tt> 72 78 __FILE__</tt>, and <tt>__LINE__</tt> is sent to output stream <b> 73 79 BOOST_ASSERT_MSG_OSTREAM</b> 74 80 and <code>std::abort()</code> is called.</P> 81 <P> <b>BOOST_ASSERT_MSG_CURRENT_FUNCTION_NAME</b> defines the macro, used to get current function name. 82 It defaults to <a href="current_function.html">BOOST_CURRENT_FUNCTION</a>. 83 <code>BOOST_CURRENT_FUNCTION</code> can produce very long names, that may lead to huge size of output files. 84 Users may define <b>BOOST_ASSERT_MSG_CURRENT_FUNCTION_NAME</b> before including <STRONG><boost/assert.hpp></STRONG> 85 to specify a different current function macro (for example to shorter but not portable __FUNCTION__ macro or to 86 "(unknown)" value). </P> 75 87 <P> <b>BOOST_ASSERT_MSG_OSTREAM</b> defines the output stream. It defaults to <code>std::cerr</code>. 76 88 Integrated development environments (IDE's) like Microsoft Visual Studio 77 89 may produce easier to understand output if messages go to a different … … 81 93 is included, instead of sending a error message to an output 82 94 stream, this expression is evaluated</P> 83 95 <blockquote> 84 <P><tt>::boost::assertion_failed_msg(#expr, msg, <a href="current_function.html">BOOST_CURRENT_FUNCTION</a>,96 <P><tt>::boost::assertion_failed_msg(#expr, msg, BOOST_ASSERT_MSG_CURRENT_FUNCTION_NAME, 85 97 __FILE__, __LINE__)</tt></P> 86 98 </blockquote> 87 99 <P><STRONG>assertion_failed_msg</STRONG> is declared in <STRONG><boost/assert.hpp></STRONG>
