[Bug c/29827] Assigning function with a char param emits a spurious warning
pinskia at gcc dot gnu dot org
gcc-bugzilla@gcc.gnu.org
Tue Nov 14 10:09:00 GMT 2006
------- 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
More information about the Gcc-bugs
mailing list