64,642
社区成员
发帖
与我相关
我的任务
分享
struct A
{
typedef int VT;
int a;
};
int _tmain(int argc, _TCHAR* argv[])
{
//TODO: tmain
//std::cout<<fun(11);
A a;
decltype(a.a) aa;
//decltype(A::a) aa2; // error C2597: 对非静态成员“A::a”的非法引用
A::VT av;
//a.VT av2; // error C2274: “函数样式转换”: 位于“.”运算符右边时非法
//decltype(a.VT) aa2; // error C2274: “函数样式转换”: 位于“.”运算符右边时非法
getchar();
return 0;
}
#define insttype(inst__) std::enable_if<true, decltype(inst__)>::type
#define mbrtype(cls__, mbr__) std::enable_if<true, decltype(((cls__*)(0))->mbr__)>::type