C++typedef struct和struct的区别
#include "pch.h"
#include
struct struct1
{
int a;
char b;
char* c;
}test1;//定义结构体变量
typedef struct struct2
{
int a;
char b;
char* c;
}test2;//定义结构体类型
int main()
{
test1.a = 10;
test2 *t2=new test2();
t2->a = 20;
}