<?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[Wie kann ich testen, ob ein auto_ptr gültig ist?]]></title><description><![CDATA[<p>Ich möchte testen, ob ein auto_ptr noch gültig ist (z.B. nach Zuweisung wird er ja auf NULL gesetzt)? Ein Vergleich mit NULL geht nicht, weil == oder != für auto_ptr nicht definiert ist. Mit Prüfen auf typeid geht es auch nicht, weil diese nach dem &quot;delete&quot; noch gleich ist.</p>
]]></description><link>https://www.c-plusplus.net/forum/topic/154021/wie-kann-ich-testen-ob-ein-auto_ptr-gültig-ist</link><generator>RSS for Node</generator><lastBuildDate>Mon, 07 Sep 2026 19:15:20 GMT</lastBuildDate><atom:link href="https://www.c-plusplus.net/forum/topic/154021.rss" rel="self" type="application/rss+xml"/><pubDate>Sun, 23 Jul 2006 15:57:21 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to Wie kann ich testen, ob ein auto_ptr gültig ist? on Sun, 23 Jul 2006 15:57:21 GMT]]></title><description><![CDATA[<p>Ich möchte testen, ob ein auto_ptr noch gültig ist (z.B. nach Zuweisung wird er ja auf NULL gesetzt)? Ein Vergleich mit NULL geht nicht, weil == oder != für auto_ptr nicht definiert ist. Mit Prüfen auf typeid geht es auch nicht, weil diese nach dem &quot;delete&quot; noch gleich ist.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1102641</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1102641</guid><dc:creator><![CDATA[hauseria]]></dc:creator><pubDate>Sun, 23 Jul 2006 15:57:21 GMT</pubDate></item><item><title><![CDATA[Reply to Wie kann ich testen, ob ein auto_ptr gültig ist? on Sun, 23 Jul 2006 15:59:46 GMT]]></title><description><![CDATA[<pre><code class="language-cpp">if(ap.get() != NULL)
</code></pre>
]]></description><link>https://www.c-plusplus.net/forum/post/1102645</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1102645</guid><dc:creator><![CDATA[ap]]></dc:creator><pubDate>Sun, 23 Jul 2006 15:59:46 GMT</pubDate></item><item><title><![CDATA[Reply to Wie kann ich testen, ob ein auto_ptr gültig ist? on Sun, 23 Jul 2006 18:37:38 GMT]]></title><description><![CDATA[<pre><code class="language-cpp">if (ap)
// bzw.
if (!ap)
</code></pre>
<p>oder?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1102744</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1102744</guid><dc:creator><![CDATA[Bashar]]></dc:creator><pubDate>Sun, 23 Jul 2006 18:37:38 GMT</pubDate></item><item><title><![CDATA[Reply to Wie kann ich testen, ob ein auto_ptr gültig ist? on Sun, 23 Jul 2006 18:46:04 GMT]]></title><description><![CDATA[<p>Bashar schrieb:</p>
<blockquote>
<pre><code class="language-cpp">if (ap)
// bzw.
if (!ap)
</code></pre>
<p>oder?</p>
</blockquote>
<p>Nein. <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f61e.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--disappointed_face"
      title=":("
      alt="😞"
    /></p>
]]></description><link>https://www.c-plusplus.net/forum/post/1102751</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1102751</guid><dc:creator><![CDATA[leider nicht]]></dc:creator><pubDate>Sun, 23 Jul 2006 18:46:04 GMT</pubDate></item><item><title><![CDATA[Reply to Wie kann ich testen, ob ein auto_ptr gültig ist? on Sun, 23 Jul 2006 19:10:31 GMT]]></title><description><![CDATA[<p>Josuttis:</p>
<blockquote>
<p>T* auto_ptr::get() const throw()<br />
• Returns the address of the object that the auto_ptr owns (if any).<br />
• Returns the null pointer if the auto_ptr does not own an object.<br />
• This call does not change the ownership. Thus, on exit the auto_ptr still owns the object that it owned on entry (if any).</p>
</blockquote>
]]></description><link>https://www.c-plusplus.net/forum/post/1102757</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1102757</guid><dc:creator><![CDATA[Erhard Henkes]]></dc:creator><pubDate>Sun, 23 Jul 2006 19:10:31 GMT</pubDate></item></channel></rss>