<?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[Problem mit Template Klassen Konstruktor]]></title><description><![CDATA[<p>Hi, ich hab folgenden Compiler Fehler:</p>
<pre><code>error: expected unqualified-id before 'class'
</code></pre>
<p>Bei folgendem Code:</p>
<pre><code class="language-cpp">template &lt;typename T&gt; class vector4d;

template &lt;typename T&gt; class vector3d
{
    vector3d(const vector4d&lt;T&gt; &amp;other);
    /* ... */
};

template &lt;typename T&gt; class vector4d : public vector3d&lt;T&gt;
{
    /* ... */
};

// Hier kommt der Fehler:
template &lt;typename T&gt; vector3d&lt;T&gt;::class vector3d&lt;T&gt;(const vector4d&lt;T&gt; &amp;other) { /* ... */ }
</code></pre>
<p>Wie muss das richtig aussehen?</p>
]]></description><link>https://www.c-plusplus.net/forum/topic/284924/problem-mit-template-klassen-konstruktor</link><generator>RSS for Node</generator><lastBuildDate>Fri, 21 Aug 2026 17:24:57 GMT</lastBuildDate><atom:link href="https://www.c-plusplus.net/forum/topic/284924.rss" rel="self" type="application/rss+xml"/><pubDate>Mon, 11 Apr 2011 13:05:35 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to Problem mit Template Klassen Konstruktor on Mon, 11 Apr 2011 13:06:09 GMT]]></title><description><![CDATA[<p>Hi, ich hab folgenden Compiler Fehler:</p>
<pre><code>error: expected unqualified-id before 'class'
</code></pre>
<p>Bei folgendem Code:</p>
<pre><code class="language-cpp">template &lt;typename T&gt; class vector4d;

template &lt;typename T&gt; class vector3d
{
    vector3d(const vector4d&lt;T&gt; &amp;other);
    /* ... */
};

template &lt;typename T&gt; class vector4d : public vector3d&lt;T&gt;
{
    /* ... */
};

// Hier kommt der Fehler:
template &lt;typename T&gt; vector3d&lt;T&gt;::class vector3d&lt;T&gt;(const vector4d&lt;T&gt; &amp;other) { /* ... */ }
</code></pre>
<p>Wie muss das richtig aussehen?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/2047516</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2047516</guid><dc:creator><![CDATA[LukasBanana]]></dc:creator><pubDate>Mon, 11 Apr 2011 13:06:09 GMT</pubDate></item><item><title><![CDATA[Reply to Problem mit Template Klassen Konstruktor on Mon, 11 Apr 2011 13:31:38 GMT]]></title><description><![CDATA[<pre><code class="language-cpp">template &lt;typename T&gt; vector3d&lt;T&gt;::vector3d(const vector4d&lt;T&gt; &amp;other) { /* ... */ }
</code></pre>
]]></description><link>https://www.c-plusplus.net/forum/post/2047529</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2047529</guid><dc:creator><![CDATA[camper]]></dc:creator><pubDate>Mon, 11 Apr 2011 13:31:38 GMT</pubDate></item><item><title><![CDATA[Reply to Problem mit Template Klassen Konstruktor on Mon, 11 Apr 2011 13:36:34 GMT]]></title><description><![CDATA[<p>Danke, jetzt funktioniert's <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f642.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--slightly_smiling_face"
      title=":)"
      alt="🙂"
    /></p>
]]></description><link>https://www.c-plusplus.net/forum/post/2047531</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2047531</guid><dc:creator><![CDATA[LukasBanana]]></dc:creator><pubDate>Mon, 11 Apr 2011 13:36:34 GMT</pubDate></item></channel></rss>