结果:
static foo
static foo
foo
friend foo, 1
friend foo1, 1
编译环境:
g++ (GCC) 4.1.2 20071124 (Red Hat 4.1.2-42)
Copyright (C) 2006 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
C++成员函数指针示例

本文通过一个C++示例程序展示了如何使用成员函数指针和静态成员函数,包括不同类型的成员函数指针的定义及调用过程。此外还涉及了友元函数的应用。
1367

被折叠的 条评论
为什么被折叠?



