<?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[Schnelle Frage]]></title><description><![CDATA[<p>Hey hey,</p>
<p>ganz schnell: Gibt es einen Unterschied zwischen</p>
<p>void foo();</p>
<p>und</p>
<p>void foo(void);</p>
<p>Dank &amp; Gruß!</p>
]]></description><link>https://www.c-plusplus.net/forum/topic/278984/schnelle-frage</link><generator>RSS for Node</generator><lastBuildDate>Mon, 24 Aug 2026 19:11:33 GMT</lastBuildDate><atom:link href="https://www.c-plusplus.net/forum/topic/278984.rss" rel="self" type="application/rss+xml"/><pubDate>Thu, 16 Dec 2010 17:24:34 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to Schnelle Frage on Thu, 16 Dec 2010 17:24:34 GMT]]></title><description><![CDATA[<p>Hey hey,</p>
<p>ganz schnell: Gibt es einen Unterschied zwischen</p>
<p>void foo();</p>
<p>und</p>
<p>void foo(void);</p>
<p>Dank &amp; Gruß!</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1995477</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1995477</guid><dc:creator><![CDATA[Interessant!]]></dc:creator><pubDate>Thu, 16 Dec 2010 17:24:34 GMT</pubDate></item><item><title><![CDATA[Reply to Schnelle Frage on Thu, 16 Dec 2010 17:30:48 GMT]]></title><description><![CDATA[<p>Hallo,</p>
<p>nein, es ist das selbe.</p>
<p>Gruß CHristopher</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1995479</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1995479</guid><dc:creator><![CDATA[TheChrissy]]></dc:creator><pubDate>Thu, 16 Dec 2010 17:30:48 GMT</pubDate></item><item><title><![CDATA[Reply to Schnelle Frage on Thu, 16 Dec 2010 17:33:55 GMT]]></title><description><![CDATA[<p>siehe auch <a href="http://www.cplusplus.com/doc/tutorial/functions/#void" rel="nofollow">http://www.cplusplus.com/doc/tutorial/functions/#void</a></p>
]]></description><link>https://www.c-plusplus.net/forum/post/1995481</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1995481</guid><dc:creator><![CDATA[inter2k3]]></dc:creator><pubDate>Thu, 16 Dec 2010 17:33:55 GMT</pubDate></item><item><title><![CDATA[Reply to Schnelle Frage on Thu, 16 Dec 2010 17:35:49 GMT]]></title><description><![CDATA[<p>Hey, danke für die schnellen Antworten.</p>
<p>Aber warum werden Funktionen dann so oft mit foo(void) angegeben.. ist das nicht nur unnötige Schreibarbeit, oder steckt etwa mehr dahinter? Eine Spezifikation eventuell??</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1995482</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1995482</guid><dc:creator><![CDATA[Interesssant!]]></dc:creator><pubDate>Thu, 16 Dec 2010 17:35:49 GMT</pubDate></item><item><title><![CDATA[Reply to Schnelle Frage on Thu, 16 Dec 2010 17:39:02 GMT]]></title><description><![CDATA[<p>Macht man in C</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1995483</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1995483</guid><dc:creator><![CDATA[CFrickler]]></dc:creator><pubDate>Thu, 16 Dec 2010 17:39:02 GMT</pubDate></item><item><title><![CDATA[Reply to Schnelle Frage on Thu, 16 Dec 2010 18:01:46 GMT]]></title><description><![CDATA[<p>Interesssant! schrieb:</p>
<blockquote>
<p>Aber warum werden Funktionen dann so oft mit foo(void) angegeben..</p>
</blockquote>
<p>Das macht man in C++ doch gar nicht. Du guckst Dir wahrscheinlich C-Quellcode an. Da macht das einen Unterschied. In C++ kann man das void weglassen, ohne dass es die Bedeutung verändert. Man kann mit oder ohne void eine Funktion deklarieren, die keine Parameter entgegen nimmt. In C bedeutet das Weglassen von void hier nur, dass man die Parametertypen nicht weiter spezifizieren will. Somit kann der C Compiler auch nicht überprüfen, ob Du die Funktion richtig aufrufst oder nicht. Folgendes wird zB von einem C-Compiler gefressen:</p>
<pre><code class="language-cpp">void f();

void g(void) {
  f(3.14159265);
}
</code></pre>
<p>Mit einem zusätzlichen void klappt das dann nicht mehr:</p>
<pre><code class="language-cpp">void f(void);

void g(void) {
  f(3.14159265);
}
</code></pre>
<pre><code>test.c:4:3: error: too many arguments to function 'foo'
</code></pre>
]]></description><link>https://www.c-plusplus.net/forum/post/1995487</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1995487</guid><dc:creator><![CDATA[krümelkacker]]></dc:creator><pubDate>Thu, 16 Dec 2010 18:01:46 GMT</pubDate></item><item><title><![CDATA[Reply to Schnelle Frage on Thu, 16 Dec 2010 18:49:39 GMT]]></title><description><![CDATA[<p>krümelkacker schrieb:</p>
<blockquote>
<p>Das macht man in C++ doch gar nicht.</p>
</blockquote>
<p>Man nicht, aber Microsoft schon.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1995502</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1995502</guid><dc:creator><![CDATA[manni66]]></dc:creator><pubDate>Thu, 16 Dec 2010 18:49:39 GMT</pubDate></item><item><title><![CDATA[Reply to Schnelle Frage on Thu, 16 Dec 2010 18:50:53 GMT]]></title><description><![CDATA[<p><a class="plugin-mentions-user plugin-mentions-a" href="https://www.c-plusplus.net/forum/uid/24868">@krümelkacker</a> ich arbeite zwar nicht mit C aber wie kann der Programmierer mit dem übergebenen Parameter arbeiten?</p>
<p>va_list? oder gibt es da noch etwas anderes?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1995504</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1995504</guid><dc:creator><![CDATA[oheoheh]]></dc:creator><pubDate>Thu, 16 Dec 2010 18:50:53 GMT</pubDate></item><item><title><![CDATA[Reply to Schnelle Frage on Thu, 16 Dec 2010 19:10:28 GMT]]></title><description><![CDATA[<p>oheoheh schrieb:</p>
<blockquote>
<p><a class="plugin-mentions-user plugin-mentions-a" href="https://www.c-plusplus.net/forum/uid/24868">@krümelkacker</a> ich arbeite zwar nicht mit C aber wie kann der Programmierer mit dem übergebenen Parameter arbeiten?</p>
<p>va_list? oder gibt es da noch etwas anderes?</p>
</blockquote>
<p>Wenn ich deine Frage richtig verstehe, dann solltest du mal bei einem guten Grundlagen Buch anfangen.<br />
Parameter benutzt man, indem man sie angibt:</p>
<pre><code class="language-cpp">void foo(int i)
{
 //...
}

int main()
{
 foo(2);
}
</code></pre>
]]></description><link>https://www.c-plusplus.net/forum/post/1995511</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1995511</guid><dc:creator><![CDATA[drakon]]></dc:creator><pubDate>Thu, 16 Dec 2010 19:10:28 GMT</pubDate></item><item><title><![CDATA[Reply to Schnelle Frage on Thu, 16 Dec 2010 19:15:56 GMT]]></title><description><![CDATA[<blockquote>
<p>Wenn ich deine Frage richtig verstehe</p>
</blockquote>
<p>Nein, hast du nicht. Er bezog sich auf folgenes Beispiel:</p>
<pre><code class="language-cpp">void f();

void g(void) {
  f(3.14159265);
}
</code></pre>
<p>Die Frage ist: Wie kann man innerhalb von f auf 3.13159265 zugreifen?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1995513</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1995513</guid><dc:creator><![CDATA[Kontext]]></dc:creator><pubDate>Thu, 16 Dec 2010 19:15:56 GMT</pubDate></item><item><title><![CDATA[Reply to Schnelle Frage on Thu, 16 Dec 2010 19:31:57 GMT]]></title><description><![CDATA[<p>Vllt. Asm ?<br />
mov bla,[esp + x]</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1995516</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1995516</guid><dc:creator><![CDATA[Felixxx]]></dc:creator><pubDate>Thu, 16 Dec 2010 19:31:57 GMT</pubDate></item><item><title><![CDATA[Reply to Schnelle Frage on Thu, 16 Dec 2010 19:52:45 GMT]]></title><description><![CDATA[<p>Wow ist das cool! Hey kennt ihr noch mehr interessante (nicht immer selbstverständliche) sachen aus C? Ich könnte damit Leute mit seltsamem verhalten gut aussehenden Programmen ärgern.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1995523</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1995523</guid><dc:creator><![CDATA[neoexpert]]></dc:creator><pubDate>Thu, 16 Dec 2010 19:52:45 GMT</pubDate></item><item><title><![CDATA[Reply to Schnelle Frage on Thu, 16 Dec 2010 20:29:34 GMT]]></title><description><![CDATA[<p>Felixxx schrieb:</p>
<blockquote>
<p>Vllt. Asm ?<br />
mov bla,[esp + x]</p>
</blockquote>
<p>Digga, was ist 'bla'? :xmas1:<br />
Du hast eine Funktion:</p>
<pre><code class="language-cpp">void foo() 
{
    // Was steht hier wenn ich foo(3.123123); aufrufe?
}
</code></pre>
]]></description><link>https://www.c-plusplus.net/forum/post/1995541</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1995541</guid><dc:creator><![CDATA[EyDigga]]></dc:creator><pubDate>Thu, 16 Dec 2010 20:29:34 GMT</pubDate></item><item><title><![CDATA[Reply to Schnelle Frage on Thu, 16 Dec 2010 20:56:18 GMT]]></title><description><![CDATA[<p>Wenn du variable Parameterlisten willst, dann schau dir das an:<br />
<a href="http://www.cplusplus.com/reference/clibrary/cstdarg/va_start/" rel="nofollow">http://www.cplusplus.com/reference/clibrary/cstdarg/va_start/</a></p>
]]></description><link>https://www.c-plusplus.net/forum/post/1995548</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1995548</guid><dc:creator><![CDATA[ghjghjgh]]></dc:creator><pubDate>Thu, 16 Dec 2010 20:56:18 GMT</pubDate></item><item><title><![CDATA[Reply to Schnelle Frage on Thu, 16 Dec 2010 21:08:18 GMT]]></title><description><![CDATA[<p>EyDigga schrieb:</p>
<blockquote>
<p>Felixxx schrieb:</p>
<blockquote>
<p>Vllt. Asm ?<br />
mov bla,[esp + x]</p>
</blockquote>
<p>Digga, was ist 'bla'? :xmas1:<br />
Du hast eine Funktion:</p>
<pre><code class="language-cpp">void foo() 
{
    // Was steht hier wenn ich foo(3.123123); aufrufe?
}
</code></pre>
</blockquote>
<p>Ja, kann man sich dazudenken, nehme ich mal an. Vorposter scheint aber eh was niceres zu kennen.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1995555</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1995555</guid><dc:creator><![CDATA[-Felix-_outloggd]]></dc:creator><pubDate>Thu, 16 Dec 2010 21:08:18 GMT</pubDate></item><item><title><![CDATA[Reply to Schnelle Frage on Sat, 18 Dec 2010 19:01:37 GMT]]></title><description><![CDATA[<p>neoexpert schrieb:</p>
<blockquote>
<p>Wow ist das cool! Hey kennt ihr noch mehr interessante (nicht immer selbstverständliche) sachen aus C? Ich könnte damit Leute mit seltsamem verhalten gut aussehenden Programmen ärgern.</p>
</blockquote>
<p>hmm das war keine Ironie. Kennt ihr welche?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1996370</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1996370</guid><dc:creator><![CDATA[neoexpert]]></dc:creator><pubDate>Sat, 18 Dec 2010 19:01:37 GMT</pubDate></item><item><title><![CDATA[Reply to Schnelle Frage on Sat, 18 Dec 2010 19:17:26 GMT]]></title><description><![CDATA[<p>Hach, das erinnert mich an die Zeit, in der ich angefangen habe C zu lernen, mit einem super Buch. Bis zur letzten Seite wurde nirgendwo erwähnt, wie man Funktionen schreibt, die keinen Parameter haben oder nichts zurückgeben. Hoffentlich habe ich das noch irgendwo in der Gerümpelkammer, ich würde es gerne zeremoniell verbrennen!</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1996381</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1996381</guid><dc:creator><![CDATA[[[global:guest]]]]></dc:creator><pubDate>Sat, 18 Dec 2010 19:17:26 GMT</pubDate></item></channel></rss>