1
我有兩個需要相互引用的結構,但是無論我先放哪一個都會拋出錯誤,因爲我使用的是未識別的類型。相互引用的結構
typedef struct _BLOCK
{
int size;
int offset;
struct _BLOCK *nextBlock;
struct _BLOCK *prevBlock;
Pool* parent; //here
} Block;
typedef struct _POOL
{
int size;
void* memory;
Block* Allocated;
Block* Unallocated;
} Pool;
有什麼辦法可以解決這個問題?
以'_'開頭的名稱後面跟着一個大寫字母或另一個下劃線爲實現保留。 **不要使用它們**。 – Olaf