title: GCC error: array type has incomplete element type
body: <p>I'm trying to build a module table for my application.</p>
  
  <pre><code>/*** MODULE TABLE DEFINTION ***/ 
  struct ModuleInfo
  {
   char use_module;     // 0 = don't use, 1 = use, -1 for end of list
   char module_name[64];    // english name of module
   int(*module_init)(void);   // module initialization callback
   void(*module_tick)(void);   // module tick callback
   void(*module_end)(void);   // module end callback
   void *config_table;     // config table
  };
  
  /*** MODULE TABLE ***/
  const struct ModuleTable module_table[] = {
   {
    1, "GPS/NMEA over RS232",
    gps_nmea_rs232_init,
    gps_nmea_rs232_tick, 
    gps_nmea_rs232_end,
    NULL
   },
   // end table
   {
    -1, NULL, NULL, NULL, NULL
   } 
  };
  </code></pre>
  
  <p>The table stores a list of modules, with pointers to initialization, tick and termination functions to be called at appropriate intervals.</p>
  
  <p>I am building this using MPLAB C30, which is a version of GCC 3.23 (I think?) for specific PIC microcontrollers. </p>
  
  <p>However when I try to compile this, I get:</p>
  
  <pre><code>In file included from main.c:3:
  
  modules.h:67: error: array type has incomplete element type
  </code></pre>
  
  <p>The table should be const if possible because I have lots of (edit: ROM) spare and not much (edit: RAM) spare. I cannot figure out why this is not working.</p>