mayer (10/25/82)
I have a problem with the C compiler under 4.1bsd UNIX.
The program:
extern void foo();
test_one()
{
void (*bar)();
bar = foo;
}
produces the error message:
"tst1.c", line 7: operands of = have incompatible types
The same program, with "int" substitued for "void" compiles perfectly.
Jim Mayer
rochester!mayer at seismo
jhh (10/26/82)
The type void is a bastard data type. Initializations or any reference to the address of a function defined as void will not work. The `correct' method of using a void is to say `void int f();' (KLUDGE KLUDGE KLUDGE). At least that was the response I got after submitting a Modification Request to USG. Perhaps this should be posted to net.jokes? It does work though. John Haller