0
中的结构我有下面的C程序,在Visual Studio下编译但在QT 5.2中失败。QT/mingw - struct struct
#include <stdio.h>
struct structA
{
int x;
struct structB
{
int d;
} y;
};
int main(int argc, char *argv[])
{
struct structA ad;
struct structB ab;
return 0;
}
我在QT得到的错误是
error: aggregate 'structB ab' has incomplete type and cannot be definedstruct structB ab;
任何想法,为什么这个工程在Visual Studio中,而不是QT?
是'c'编译器还是'C++'编译器? – UmNyobe