对typedef 的结构体进行前置声明,需要先声明结构体,再进行typedef,如:
</pre><p><pre name="code" class="cpp">A.h
typedef _StructA
{
}StructA;
B.h
//前置声明
struct _StructA;
typedef _StructA StructA;
对typedef 的结构体进行前置声明,需要先声明结构体,再进行typedef,如:
</pre><p><pre name="code" class="cpp">A.h
typedef _StructA
{
}StructA;
B.h
//前置声明
struct _StructA;
typedef _StructA StructA;