compile error: #94-D: the size of an array must be greater than zero with keil

20 Jan 2011

hello

I try to compile blueUSB project offline with keil uVision, &  it give me "error:  #94-D: the size of an array must be greater than zero"

code

typedef struct
{
u8  AddressSpecific[0]; // BDADDR,psm etc  ;//error here
} SocketAddrHdr;

class SocketInternal
{
public:

u8 ID;
u8 State;
u8 Type;
u8 B0;
SocketCallback Callback;
void* userData;
u8  Data[0];    // Extra socket data starts here      ;//error here

void Recv(const u8* data, int len)
{
Callback(ID,(SocketState)State,data,len,userData);
}

void SetState(SocketState state)
{
State = state;
Callback(ID,(SocketState)State,0,0,userData);
}
};

anyone could help?

thanks

12 Apr 2015

Nobody can answers ? I have same problems

Please log in to post a reply.