<?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[ExceptionGehtNicht]]></title><description><![CDATA[<p>Hallo, warum wird in folgendem Code nichts auf der Console ausgegeben?</p>
<pre><code class="language-cpp">void catch_global() {
 try {
  throw;
 }
 catch (...) {
  std::wcerr &lt;&lt; L&quot;Error!&quot; &lt;&lt; std::endl;
 }
 abort();
}

int main() {
 std::set_terminate(catch_global);
 throw;
 return 0;
}
</code></pre>
]]></description><link>https://www.c-plusplus.net/forum/topic/290956/exceptiongehtnicht</link><generator>RSS for Node</generator><lastBuildDate>Tue, 18 Aug 2026 00:21:35 GMT</lastBuildDate><atom:link href="https://www.c-plusplus.net/forum/topic/290956.rss" rel="self" type="application/rss+xml"/><pubDate>Sun, 07 Aug 2011 18:23:26 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to ExceptionGehtNicht on Sun, 07 Aug 2011 18:23:26 GMT]]></title><description><![CDATA[<p>Hallo, warum wird in folgendem Code nichts auf der Console ausgegeben?</p>
<pre><code class="language-cpp">void catch_global() {
 try {
  throw;
 }
 catch (...) {
  std::wcerr &lt;&lt; L&quot;Error!&quot; &lt;&lt; std::endl;
 }
 abort();
}

int main() {
 std::set_terminate(catch_global);
 throw;
 return 0;
}
</code></pre>
]]></description><link>https://www.c-plusplus.net/forum/post/2103092</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2103092</guid><dc:creator><![CDATA[Global Exception Handling]]></dc:creator><pubDate>Sun, 07 Aug 2011 18:23:26 GMT</pubDate></item><item><title><![CDATA[Reply to ExceptionGehtNicht on Sun, 07 Aug 2011 18:29:04 GMT]]></title><description><![CDATA[<p>&quot; <code>throw;</code> &quot; wirft nur weiter. Teste mal z.B. &quot; <code>throw 0;</code> &quot;</p>
]]></description><link>https://www.c-plusplus.net/forum/post/2103093</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2103093</guid><dc:creator><![CDATA[EOutOfResources]]></dc:creator><pubDate>Sun, 07 Aug 2011 18:29:04 GMT</pubDate></item><item><title><![CDATA[Reply to ExceptionGehtNicht on Sun, 07 Aug 2011 18:59:34 GMT]]></title><description><![CDATA[<p>Ok, das geht soweit, aber was wenn ich zusätzlich noch eigene (nicht behandelte) Exceptions abfangen möchte?</p>
<pre><code class="language-cpp">void catch_global() {
 try {
  throw;
 }
catch(const MyException&amp; exception)
{
  std::wcerr &lt;&lt; L&quot;MyException!&quot; &lt;&lt; std::endl;
}
 catch (...) {
  std::wcerr &lt;&lt; L&quot;Error!&quot; &lt;&lt; std::endl;
 }
 abort();
}

int main() {
 std::set_terminate(catch_global);
 throw MyException();
 return 0;
}
</code></pre>
<p>Es wird leider nur &quot;Error!&quot; ausgegeben.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/2103102</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2103102</guid><dc:creator><![CDATA[Global Exception Handling]]></dc:creator><pubDate>Sun, 07 Aug 2011 18:59:34 GMT</pubDate></item><item><title><![CDATA[Reply to ExceptionGehtNicht on Sun, 07 Aug 2011 19:05:48 GMT]]></title><description><![CDATA[<p>Wie kommst du auf die Idee, mit dem terminate Handler Exceptions fangen zu können?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/2103104</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2103104</guid><dc:creator><![CDATA[manni66]]></dc:creator><pubDate>Sun, 07 Aug 2011 19:05:48 GMT</pubDate></item><item><title><![CDATA[Reply to ExceptionGehtNicht on Sun, 07 Aug 2011 19:10:45 GMT]]></title><description><![CDATA[<p>Weil ich das hier so gelesen habe:<br />
<a href="http://www.extinguishedscholar.com/wpglob/?p=176" rel="nofollow">http://www.extinguishedscholar.com/wpglob/?p=176</a></p>
]]></description><link>https://www.c-plusplus.net/forum/post/2103110</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2103110</guid><dc:creator><![CDATA[Global Exception Handling]]></dc:creator><pubDate>Sun, 07 Aug 2011 19:10:45 GMT</pubDate></item><item><title><![CDATA[Reply to ExceptionGehtNicht on Sun, 07 Aug 2011 21:00:50 GMT]]></title><description><![CDATA[<p>Ich kann weder im Standard noch in TC++PL etwas finden, das auch andeutet, dass das funktioniert. Lediglich für den unexpected Handler wird gesagt, dass ein rethrow möglich sei. Da auch dein Experiment fehlschlägt, gehts wohl nicht bzw. nur in manchen Implementierungen.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/2103158</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2103158</guid><dc:creator><![CDATA[manni66]]></dc:creator><pubDate>Sun, 07 Aug 2011 21:00:50 GMT</pubDate></item><item><title><![CDATA[Reply to ExceptionGehtNicht on Sun, 07 Aug 2011 21:29:39 GMT]]></title><description><![CDATA[<p>Normalerweise macht man deswegen um den in Frage kommenden Code einfach selbst einen try-catch-Block.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/2103166</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2103166</guid><dc:creator><![CDATA[Eisflamme]]></dc:creator><pubDate>Sun, 07 Aug 2011 21:29:39 GMT</pubDate></item><item><title><![CDATA[Reply to ExceptionGehtNicht on Sun, 07 Aug 2011 21:37:56 GMT]]></title><description><![CDATA[<p>Oder benutzt platform-spezifische Funktionen, wie z.B. SetUnhandledExceptionFilter(..) unter Windows:<br />
<a href="http://msdn.microsoft.com/en-us/library/ms680634.aspx" rel="nofollow">http://msdn.microsoft.com/en-us/library/ms680634.aspx</a></p>
<p>Oder _set_se_translator(..), <a href="http://msdn.microsoft.com/en-us/library/5z4bw5h5.aspx" rel="nofollow">http://msdn.microsoft.com/en-us/library/5z4bw5h5.aspx</a></p>
]]></description><link>https://www.c-plusplus.net/forum/post/2103167</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2103167</guid><dc:creator><![CDATA[theta]]></dc:creator><pubDate>Sun, 07 Aug 2011 21:37:56 GMT</pubDate></item></channel></rss>