<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Incomplete type error on compiling a basic C++ program in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/incomplete-type-error-on-compiling-a-basic-c-program/m-p/4420979#M682296</link>
    <description>(The correct forum for aCC6 is: HP-UX &amp;gt; languages:&lt;BR /&gt;&lt;A href="http://forums.itrc.hp.com/service/forums/categoryhome.do?categoryId=150" target="_blank"&gt;http://forums.itrc.hp.com/service/forums/categoryhome.do?categoryId=150&lt;/A&gt;&lt;BR /&gt;The moderators have been asked to move it.)&lt;BR /&gt;&lt;BR /&gt;Your source is illegal.  You can't use an incomplete type as a container parm.&lt;BR /&gt;&lt;BR /&gt;&amp;gt;is there any way around it?&lt;BR /&gt;&lt;BR /&gt;You could have subTokens be a tokenMap*.&lt;BR /&gt;Or have a map&lt;STRING&gt;.&lt;BR /&gt;Or possibly convert cs_cmdmatrix_s to a template?&lt;BR /&gt;&lt;BR /&gt;Note: In C++ it is pretty silly to have typedefs like this:&lt;BR /&gt;typedef struct cs_cmdmatrix_s cs_cmdmatrix_t;&lt;BR /&gt;A class tag is a type.  So just define and use it as: cs_cmdmatrix&lt;/STRING&gt;</description>
    <pubDate>Fri, 15 May 2009 20:18:54 GMT</pubDate>
    <dc:creator>Dennis Handly</dc:creator>
    <dc:date>2009-05-15T20:18:54Z</dc:date>
    <item>
      <title>Incomplete type error on compiling a basic C++ program</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/incomplete-type-error-on-compiling-a-basic-c-program/m-p/4420978#M682295</link>
      <description>While trying to use the forward declaration of a struct within a STL map decl, it gives the foll error&lt;BR /&gt;&lt;BR /&gt;"/opt/aCC/include_std/utility", line 100: error #2070: incomplete type \ &lt;BR /&gt;is not&lt;BR /&gt;          allowed&lt;BR /&gt;      second_type second;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Is this something that has been rectified now ? Unfortunately I am trying to build something where I cannot do w/o the forward declaration, is there any way around it ? &lt;BR /&gt;&lt;BR /&gt;Here is the code that is causing the trouble. &lt;BR /&gt;&lt;BR /&gt;typedef  struct cs_cmdmatrix_s  cs_cmdmatrix_t;&lt;BR /&gt;&lt;BR /&gt;/* type to define the token name map */&lt;BR /&gt;typedef std::map&lt;STRING&gt; &amp;gt; tokenMap;&lt;BR /&gt;&lt;BR /&gt;struct cs_cmdmatrix_s{&lt;BR /&gt;&lt;BR /&gt;  int                icmdid;           &lt;BR /&gt;  .&lt;BR /&gt;  .&lt;BR /&gt;  .&lt;BR /&gt;  . &lt;BR /&gt;&lt;BR /&gt;  tokenMap           subTokens;        &lt;BR /&gt; &lt;BR /&gt;};&lt;BR /&gt;&lt;BR /&gt;&lt;/STRING&gt;</description>
      <pubDate>Fri, 15 May 2009 16:23:00 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/incomplete-type-error-on-compiling-a-basic-c-program/m-p/4420978#M682295</guid>
      <dc:creator>athakur</dc:creator>
      <dc:date>2009-05-15T16:23:00Z</dc:date>
    </item>
    <item>
      <title>Re: Incomplete type error on compiling a basic C++ program</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/incomplete-type-error-on-compiling-a-basic-c-program/m-p/4420979#M682296</link>
      <description>(The correct forum for aCC6 is: HP-UX &amp;gt; languages:&lt;BR /&gt;&lt;A href="http://forums.itrc.hp.com/service/forums/categoryhome.do?categoryId=150" target="_blank"&gt;http://forums.itrc.hp.com/service/forums/categoryhome.do?categoryId=150&lt;/A&gt;&lt;BR /&gt;The moderators have been asked to move it.)&lt;BR /&gt;&lt;BR /&gt;Your source is illegal.  You can't use an incomplete type as a container parm.&lt;BR /&gt;&lt;BR /&gt;&amp;gt;is there any way around it?&lt;BR /&gt;&lt;BR /&gt;You could have subTokens be a tokenMap*.&lt;BR /&gt;Or have a map&lt;STRING&gt;.&lt;BR /&gt;Or possibly convert cs_cmdmatrix_s to a template?&lt;BR /&gt;&lt;BR /&gt;Note: In C++ it is pretty silly to have typedefs like this:&lt;BR /&gt;typedef struct cs_cmdmatrix_s cs_cmdmatrix_t;&lt;BR /&gt;A class tag is a type.  So just define and use it as: cs_cmdmatrix&lt;/STRING&gt;</description>
      <pubDate>Fri, 15 May 2009 20:18:54 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/incomplete-type-error-on-compiling-a-basic-c-program/m-p/4420979#M682296</guid>
      <dc:creator>Dennis Handly</dc:creator>
      <dc:date>2009-05-15T20:18:54Z</dc:date>
    </item>
  </channel>
</rss>

