【发布时间】:2012-08-21 04:05:10
【问题描述】:
可能重复:
Purpose of struct, typedef struct, in C++
typedef struct vs struct definitions
我知道在 C 中声明结构有两种方式
struct point{
int x, y;
};
和:
typedef struct{
int x, y;
} point;
但是这两种方法有什么区别,我什么时候使用 typedef 方法而不是其他方法?
【问题讨论】: