title: struct in class is not a type
body: <p>I need some help with designing and returning a structure. I have done a similar type of structure and am getting an error saying: </p>
  
  <blockquote>
    <p>"The a in class c is not a type"</p>
  </blockquote>
  
  <p>How can I fix this?</p>
  
  <p>a.h  </p>
  
  <pre><code>#include&lt;stdio.h&gt;
  struct a {
     int i;
     vector&lt;abc&gt; j;
  };
  </code></pre>
  
  <p>b.h</p>
  
  <pre><code>#include &lt;a.h&gt;
  class c{
  private: 
      a a_;
      virtual bool execute();
      void compute(&amp;a a1)
  public:
      a function_name();
  }
  </code></pre>
  
  <p>b.cc</p>
  
  <pre><code>#include&lt;b.h&gt;
  c::execute()
  {
    a aa_ = function_name();
  }
  </code></pre>
  
  <p>d.cc</p>
  
  <pre><code>#include&lt;b.h&gt;
  c::a c::function_name()
  {
     compute(a_);
     return *a_;
  }
  </code></pre>