[問題] class裡的struct
如題
我想要在class裡定義一個struct
如下:
class Player{
private:
struct Friend friend[100];
};
struct Friend{
char name[10];
char birth;
};
請問有甚麼錯?
錯誤訊息:
[Error] field 'friend' has incomplete type
--
by kenn
--
※ 發信站: 批踢踢實業坊(ptt.cc), 來自: 111.242.90.9
※ 文章網址: http://www.ptt.cc/bbs/C_and_CPP/M.1417689825.A.D54.html
推
12/04 18:54, , 1F
12/04 18:54, 1F
推
12/04 21:25, , 2F
12/04 21:25, 2F
推
12/04 22:44, , 3F
12/04 22:44, 3F