<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xml:base="http://www.m2osw.com"  xmlns:dc="http://purl.org/dc/elements/1.1/">
<channel>
 <title>Made to Order Software Corporation - assert</title>
 <link>http://www.m2osw.com/taxonomy/term/392/all</link>
 <description></description>
 <language>en</language>
<item>
 <title>The assert() macro in C/C++ </title>
 <link>http://www.m2osw.com/assert_macro_in_cplusplus</link>
 <description>&lt;p&gt;&lt;span class=&quot;postbody&quot;&gt;
&lt;p&gt;This is a subject that comes back all the time in C/&lt;abbr class=&quot;mo-glossary mo-glossary-abbr&quot;  title=&quot;Object Oriented C&quot; lang=&quot;en&quot;&gt;C++&lt;/abbr&gt; boards.&lt;/p&gt;
&lt;p&gt;Should you use assertions?&lt;/p&gt;
&lt;p&gt;The answer is clearly yes. But the C/C++ assert() function is usually defined using a macro. Macros have several problems. The most common ones are: they offer no type checking, they do not warn you about weird side effects, they have a different syntax than the C/C++ language itself.&lt;/p&gt;
&lt;p&gt;One good thing: for a fast program, the debug code used to check parameters, results, etc. is gone.&lt;/p&gt;

&lt;p&gt;&lt;a href=&quot;http://www.m2osw.com/assert_macro_in_cplusplus&quot; target=&quot;_blank&quot;&gt;read more&lt;/a&gt;&lt;/p&gt;</description>
 <comments>http://www.m2osw.com/assert_macro_in_cplusplus#comments</comments>
 <pubDate>Sat, 27 Oct 2007 05:06:00 +0000</pubDate>
 <dc:creator>Alexis Wilke</dc:creator>
 <guid isPermaLink="false">88 at http://www.m2osw.com</guid>
</item>
</channel>
</rss>


