ANSI C idea: structure literals (and short constants)

Henry Spencer henry at utzoo.uucp
Sun Mar 20 11:34:35 AEST 1988


>I don't believe that K&R anywhere specify the semantics of casting structs;
>perhaps X3J11 does.  I am sure that there is a fair amount of (non-portable)
>code out there which assumes that such casts are interpreted as "take as".

I doubt it, given that most existing compilers refuse to cast structs at all.
X3J11 says you can't cast structs (except to void).  K&R doesn't mention the
issue at all, since it dates back to a time when there were no struct values
at all.
-- 
Those who do not understand Unix are |  Henry Spencer @ U of Toronto Zoology
condemned to reinvent it, poorly.    | {allegra,ihnp4,decvax,utai}!utzoo!henry



More information about the Comp.lang.c mailing list