64,282
社区成员
发帖
与我相关
我的任务
分享
Func f;
, 但是可以用于定义函数指针。
]Func* pf
因此,很多人直接定义函数地址类型,而不是函数类型。
]typedef bool (*pFunc)(const string &,const string &);
fFunc pf;
[/quote]
不太明白,
]typedef bool (*pFunc)(const string &,const string &);
那么哪个是哪个的别名啊,函数指针我知道[/quote]
前面的]是误打的。 pFunc和 bool (*)(const string &,const string &)是同一个东西。 [/quote]
懂了,thanks
Func f;
, 但是可以用于定义函数指针。
]Func* pf
因此,很多人直接定义函数地址类型,而不是函数类型。
]typedef bool (*pFunc)(const string &,const string &);
fFunc pf;
[/quote]
不太明白,
]typedef bool (*pFunc)(const string &,const string &);
那么哪个是哪个的别名啊,函数指针我知道[/quote]
前面的]是误打的。 pFunc和 bool (*)(const string &,const string &)是同一个东西。 Func f;
, 但是可以用于定义函数指针。
]Func* pf
因此,很多人直接定义函数地址类型,而不是函数类型。
]typedef bool (*pFunc)(const string &,const string &);
fFunc pf;
[/quote]
不太明白,
]typedef bool (*pFunc)(const string &,const string &);
那么哪个是哪个的别名啊,函数指针我知道Func f;
, 但是可以用于定义函数指针。
]Func* pf
因此,很多人直接定义函数地址类型,而不是函数类型。
]typedef bool (*pFunc)(const string &,const string &);
fFunc pf;
typedef wages base,*p;
可以看成两个申明语句
typedef wages base; // base其实就是double
typedef wages* p; //p其实就是double*