我正在尝试创建一个结构体,其中包含一个类型为该结构体的向量。但是,在构建时,出现了指示我在'>'之前缺少';'的错误。我不确定编译器是否认识向量作为一个东西:/我已经在我的代码中包含了。这是我目前的代码:
#include <vector>
typedef struct tnode
{
int data;
vector<tnode> children;
GLfloat x; //x coordinate of node
GLfloat y; //y coordinate of node
} tnode;
任何帮助都将不胜感激!!
std::vector<tnode>
吧? - celtschk