⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 900330_02.c

📁 linux下编程用 编译软件
💻 C
字号:
// { dg-do assemble  }// g++ 1.37.1 bug 900330_02// The C++ Reference Manual says in section 13.1:// "Two function declarations of the same name refer to the same function// if they are in the same scope and have identical argument types.  A// function member of a derived class is *not* in the same scope as a function// member of the same name in a base class."// g++ fails to correctly detect the error indicated.// Cfront 2.0 passes this test.// keywords: function, member, overloading, hidingstruct B {  int f(int);};struct D : public B {  int f(struct B);		// { dg-error "" } referred to below};void h(D* pd){  pd->f(1);		// { dg-error "" } D::f(struct B) hides B::f(int)}int main () { return 0; }

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -