900127_01.c

来自「Mac OS X 10.4.9 for x86 Source Code gcc」· C语言 代码 · 共 27 行

C
27
字号
// { dg-do assemble  }// g++ 1.36.1 bug 900127_01// g++ often fails to detect (and issue errors for) ambiguous overload// situations.  In such cases, one of the possibilities is chosen// (apparently arbitrarily). Errors should be issued instead.// Cfront 2.0 passes this test.// keywords: function overloading, ambiguityvoid foo (int);int foo (void);typedef int (*f_ptr_t1) (void);typedef void (*f_ptr_t2) (int);void bar (f_ptr_t1);		// { dg-error "" } void bar (f_ptr_t2);		// { dg-error "" } void function (){  bar (foo);			// { dg-error "" } ambiguous}int main () { return 0; }

⌨️ 快捷键说明

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