Cszie 结构体赋值错误
源码如下:
typedef struct
{
int x;
int y;
Csize size;
}IntStur;
//在函数中初始化
IntStur stur[] = {
{1,2,Csize(0,0)},
{2,2,Csize(0,0)}
};
出现错误提示
error C2440: 'initializing' : cannot convert from 'const int' to 'IntStur '
No constructor could take the source type, or constructor overload resolution was ambiguous
但是在vc2010下编译和运行都正常