Date: Thu, 28 Jan 1999 21:03:12 +1100 From: Bruce Evans <bde@zeta.org.au> To: green@unixhelp.org, jb@cimlogic.com.au Cc: archie@whistle.com, current@FreeBSD.ORG, nate@mt.sri.com, wollman@khavrinen.lcs.mit.edu Subject: Re: btokup() macro in sys/malloc.h Message-ID: <199901281003.VAA00218@godzilla.zeta.org.au>
next in thread | raw e-mail | index | archive | help
>In cases, -Wall is bogus anyway. Here's one: >foo.c:89: warning: char format, void arg (arg 2) > void *region; > printf("mem open failed: %s\n", region); Yes, it should say "warning: char * format, void * arg (arg 2)". >According to standards, a void pointer may be freely used instead of any >other type of pointer, both as an lvalue and to assign to the other pointer. There are no lvalues or assigns to another pointer here. The code does what you want (if `region' is a char * represented as a void *) only because void * has the same representation as char *. Bruce To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199901281003.VAA00218>