C++ Question: using
摘要:
看看这段代码:#include struct A { void f() { printf("A::f\n"); }};struct B : A { using A::f; // #1 void f() { printf("B::f\n"); } // #2};int main() { B().f(); #3 return 0;}运行结果会如何呢?A. B::fB. #1 编译错C. #2 编译错D. #3编译错 阅读全文
posted @ 2011-11-20 09:49 能发波 阅读(97) 评论(0) 推荐(0)