This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c/29827] Assigning function with a char param emits a spurious warning



------- Comment #1 from pinskia at gcc dot gnu dot org  2006-11-14 10:09 -------
This is not a bug, the reason is because 
void foo(char);
void (*f1)() = foo;

For foo, the prototype is not using int but instead char (or short) and f1 is
not reallying having a prototype (old K&R rules).

Comeau C rejects this code as invalid with about the same error message as our
warning.


-- 

pinskia at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|                            |INVALID


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29827


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]