title: Expected primary expression before static? Constant pointer must use
body: <p>I can't change a lot of things in this code due to certain limitations on the assignment. Here is the code:</p>
  
  <pre><code>#include &lt;iostream&gt;
  #include&lt;cstdlib&gt;
  #include&lt;cstring&gt;
  
  using namespace std;
  struct MyTime { int hours, minutes, seconds; };
  int DetermineElapsedTime(const MyTime *t1, const MyTime *t2);
  const int hourSeconds = 3600;
  const int minSeconds = 60;
  
  int DetermineElapsedTime(const MyTime *t1, const MyTime *t2)
  {//problem about static in next line
      static MyTime ((long) (((t2.hours * hourSeconds) + (t2.minutes * minSeconds) +  t2.seconds) -
                     ((t1.hours * hourSeconds) + (t1.minutes * minSeconds) + t1.seconds)));
      return(MyTime);
  }
  </code></pre>
  
  <p>It is not the entire thing but I need to somehow calculate the amount of time from primary input to the other. I will need to used setfill too.</p>
  
  <p>Anyway, does anyone know how to fix the error about needing a primary expression before static?</p>