{"id":1040,"date":"2022-08-30T15:11:23","date_gmt":"2022-08-30T15:11:23","guid":{"rendered":"https:\/\/unknownerror.org\/index.php\/2013\/11\/09\/c-using-if-true-conditional-directive-collection-of-common-programming-errors\/"},"modified":"2022-08-30T15:11:23","modified_gmt":"2022-08-30T15:11:23","slug":"c-using-if-true-conditional-directive-collection-of-common-programming-errors","status":"publish","type":"post","link":"https:\/\/unknownerror.org\/index.php\/2022\/08\/30\/c-using-if-true-conditional-directive-collection-of-common-programming-errors\/","title":{"rendered":"C++, using #if TRUE conditional directive-Collection of common programming errors"},"content":{"rendered":"<p>When using a statement like #if TRUE, what should I expect to happen? An explanation would be very appreciated! I understand how #if 1 works, but it gives a COMPLETELY different result in my code than using #if TRUE. I understand #if is a conditional directive, and what that implies; it&#8217;s just the &#8220;TRUE&#8221; (or &#8220;FALSE&#8221;) part that I don&#8217;t understand. It seems as though using it in this way never executes code following the statement. Here is an example.<\/p>\n<pre><code>#if TRUE\n     cout<\/code><\/pre>\n<p id=\"rop\"><small>Originally posted 2013-11-09 23:17:20. <\/small><\/p>","protected":false},"excerpt":{"rendered":"<p>When using a statement like #if TRUE, what should I expect to happen? An explanation would be very appreciated! I understand how #if 1 works, but it gives a COMPLETELY different result in my code than using #if TRUE. I understand #if is a conditional directive, and what that implies; it&#8217;s just the &#8220;TRUE&#8221; (or [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-1040","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"_links":{"self":[{"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/posts\/1040","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/comments?post=1040"}],"version-history":[{"count":0,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/posts\/1040\/revisions"}],"wp:attachment":[{"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/media?parent=1040"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/categories?post=1040"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/tags?post=1040"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}