Strange compile error

Aaron Stromas aaron.stromas@oracle.com
Thu Oct 19 11:12:00 GMT 2000


Greetings,

System: Linux 2.2.17
Compiler: gcc 2.95.2

I needed to recompile some old code which worked and got an error. I
might have upgraded the compiler since I built the code. I constructed a
test case that demonstrates the error. Can someone suggest what is going
on (and what is the solution). Please cc me as I'm not subscribed to the
list. TIA.

$ gcc test.c
In file included from test.c:1:
test.h:5: field `data' has incomplete type

test.h:
-----
#include "stddef.h"

typedef struct {
    signed char date[];
    size_t size;
} ENTRY;

test.c:
-----
#include "test.h"

int main()
{
}

--
Aaron Stromas    | "Tick-tick-tick!!!... ja, Pantani is weg..."
Oracle Corp      |                             BRTN commentator
+1 703.708.68.21 |                              L'Alpe d'Huez
                                            1995 Tour de France




More information about the Gcc-help mailing list