Re^2: hardcoded constants
Maarten Litmaath
maart at cs.vu.nl
Tue Dec 20 06:46:44 AEST 1988
remmers at m-net.UUCP (John H. Remmers) writes:
\...
\ #define Catspace(s,t) (strlen(s) + strlen(t) + 1)
\...
\ foo = malloc(Catspace(s,t) + sizeof('/'));
% cat c.c
main()
{
printf("%d\n", sizeof '/');
}
% cc c.c
% a.out
4
%
--
fcntl(fd, F_SETFL, FNDELAY): |Maarten Litmaath @ VU Amsterdam:
let's go weepin' in the corner! |maart at cs.vu.nl, mcvax!botter!maart
More information about the Comp.lang.c
mailing list