Prototyping char parameters in ANSI C
Guy Harris
guy at auspex.auspex.com
Tue May 2 05:39:52 AEST 1989
>In any case I know I do. :-) But I thought that in the new ANSI C (not old--
>NEW!) you could effectively circumvent this behavior and request that small
>types be received by the called function as a true char (or float, or
>whatever), size and all.
You can.
>So, I shall now ask: How do you tell the compiler that you want this *NEW*
>behavior? If a full prototype isn't good enough, what is?
A full prototype *is* good enough. The problem is that the code given
in the example doesn't have a full prototype *definition* of the
function; you have to define it as:
void f(char c)
{
...
}
More information about the Comp.lang.c
mailing list