Dumb question on dyn. mem. alloc (if(hate(novices)) dont_read();)

Ken Arnold%CGL arnold at ucsfcgl.UUCP
Mon Jul 22 08:35:01 AEST 1985


In article <921 at umcp-cs.UUCP> chris at umcp-cs.UUCP (Chris Torek) writes:
>Lint doesn't realize that malloc and calloc have been written such
>that that "possible pointer alignment problem" never occurs.  The
>thing to do is ignore the message (or teach lint how to say that
>a function returns a ``very aligned'' pointer; someone once suggested
>using /*ALIGNOK*/ similar to the way /*NOTREACHED*/ and /*ARGSUSED*/
>tell lint not to complain).

There is the (as far as I know unimplemented but) documented /*NOSTRICT*/.
This seems to have been added to handle this kind of case, but I have
never, on any version of lint I've used, seen it actually work.  This
WOULD be a good solution.
		Ken Arnold



More information about the Comp.lang.c mailing list