<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[bool true and false]]></title><description><![CDATA[<p>was ist denn unter C++ eher zu verwenden</p>
<p>BOOL oder bool<br />
TRUE oder true<br />
FALSE oder false</p>
<p>und wie ist es festgelegt</p>
<p>TRUE == 0<br />
FALSE !=0<br />
und wie ist das bei<br />
true ?=<br />
false ?=</p>
<p>weiss da jeman genau bescheid ?</p>
]]></description><link>https://www.c-plusplus.net/forum/topic/171198/bool-true-and-false</link><generator>RSS for Node</generator><lastBuildDate>Tue, 14 Jul 2026 07:27:16 GMT</lastBuildDate><atom:link href="https://www.c-plusplus.net/forum/topic/171198.rss" rel="self" type="application/rss+xml"/><pubDate>Tue, 23 Jan 2007 12:19:53 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to bool true and false on Tue, 23 Jan 2007 12:19:53 GMT]]></title><description><![CDATA[<p>was ist denn unter C++ eher zu verwenden</p>
<p>BOOL oder bool<br />
TRUE oder true<br />
FALSE oder false</p>
<p>und wie ist es festgelegt</p>
<p>TRUE == 0<br />
FALSE !=0<br />
und wie ist das bei<br />
true ?=<br />
false ?=</p>
<p>weiss da jeman genau bescheid ?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1215146</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1215146</guid><dc:creator><![CDATA[EXDW]]></dc:creator><pubDate>Tue, 23 Jan 2007 12:19:53 GMT</pubDate></item><item><title><![CDATA[Reply to bool true and false on Tue, 23 Jan 2007 12:26:52 GMT]]></title><description><![CDATA[<p>Technisch sind beide Varianten wohl gleichwertig. Allerdings mit dem Unterschied, daß BOOL normalerweise ein typedef für int ist (idR mit FALSE=0, TRUE=1) und bool ein eingebauter Typ (der nur die Werte true und false=!true enthält).</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1215157</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1215157</guid><dc:creator><![CDATA[CStoll]]></dc:creator><pubDate>Tue, 23 Jan 2007 12:26:52 GMT</pubDate></item><item><title><![CDATA[Reply to bool true and false on Tue, 23 Jan 2007 13:02:24 GMT]]></title><description><![CDATA[<p>TRUE und FALSE sind doch noch historische Überbleibsel, weil C damals kein bool hatte. Heute würde ich doch ganz normal bool benutzen, und nicht mehr die Makros.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1215187</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1215187</guid><dc:creator><![CDATA[Artchi]]></dc:creator><pubDate>Tue, 23 Jan 2007 13:02:24 GMT</pubDate></item><item><title><![CDATA[Reply to bool true and false on Tue, 23 Jan 2007 13:17:51 GMT]]></title><description><![CDATA[<p>das hatte ich auch vor<br />
aber eine frage dazu:</p>
<pre><code class="language-cpp">return static_cast&lt;bool&gt;(::SendMessage(m_Handle, LVM_DELETEITEM, Pos, 0));
</code></pre>
<p>==</p>
<pre><code class="language-cpp">warning C4800: 'LRESULT' : forcing value to bool 'true' or 'false' (performance warning)
</code></pre>
<p>wie kann ich das umgehen ?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1215203</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1215203</guid><dc:creator><![CDATA[EXDW]]></dc:creator><pubDate>Tue, 23 Jan 2007 13:17:51 GMT</pubDate></item><item><title><![CDATA[Reply to bool true and false on Tue, 23 Jan 2007 13:27:33 GMT]]></title><description><![CDATA[<p>So (zum Beispiel):</p>
<pre><code class="language-cpp">#pragma warning(disable: 4800)
return static_cast&lt;bool&gt;(::SendMessage(m_Handle, LVM_DELETEITEM, Pos, 0));	
#pragma warning(default: 4800)
</code></pre>
<p>Aber warum die int und nicht short genommen haben (bei BOOL) würd ich auch gern mal wissen <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f644.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--face_with_rolling_eyes"
      title=":rolling_eyes:"
      alt="🙄"
    /> .</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1215211</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1215211</guid><dc:creator><![CDATA[CodeFinder]]></dc:creator><pubDate>Tue, 23 Jan 2007 13:27:33 GMT</pubDate></item><item><title><![CDATA[Reply to bool true and false on Tue, 23 Jan 2007 13:29:16 GMT]]></title><description><![CDATA[<p>Lass den Cast weg - WinAPI-Funktionen geben meistens keinen bool-Wert zurück, sondern einen HRESULT, der eventuell mehr Informationen geben könnte als nur wahr/falsch.</p>
<p>(oder ignorier die Warnung)</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1215213</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1215213</guid><dc:creator><![CDATA[CStoll]]></dc:creator><pubDate>Tue, 23 Jan 2007 13:29:16 GMT</pubDate></item><item><title><![CDATA[Reply to bool true and false on Tue, 23 Jan 2007 13:39:00 GMT]]></title><description><![CDATA[<p>stimmt schon - aber wenn selbst die MSDN sagt das diese aufgerufene SendMessage methode ein TRUE oder FALSE zurueck gibt macht das ignorieren schon sinn</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1215227</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1215227</guid><dc:creator><![CDATA[EXDW]]></dc:creator><pubDate>Tue, 23 Jan 2007 13:39:00 GMT</pubDate></item><item><title><![CDATA[Reply to bool true and false on Tue, 23 Jan 2007 13:51:29 GMT]]></title><description><![CDATA[<p>ich hab fuer die BOOL to bool warnungen ein workaround<br />
ich mache statt</p>
<pre><code class="language-cpp">return static_cast&lt;bool&gt;(::SendMessage(...));
</code></pre>
<p>,</p>
<pre><code class="language-cpp">return (::SendMessage(...)) ? true : false;
</code></pre>
]]></description><link>https://www.c-plusplus.net/forum/post/1215238</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1215238</guid><dc:creator><![CDATA[EXDW]]></dc:creator><pubDate>Tue, 23 Jan 2007 13:51:29 GMT</pubDate></item><item><title><![CDATA[Reply to bool true and false on Tue, 23 Jan 2007 13:56:20 GMT]]></title><description><![CDATA[<p>Ja ich sag ja ist, nur eine Möglichkeit von vielen... So ist noch kürzer:</p>
<pre><code class="language-cpp">return (SendMessage(...) == TRUE);
</code></pre>
]]></description><link>https://www.c-plusplus.net/forum/post/1215244</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1215244</guid><dc:creator><![CDATA[CodeFinder]]></dc:creator><pubDate>Tue, 23 Jan 2007 13:56:20 GMT</pubDate></item></channel></rss>