Return to BSD News archive
Path: euryale.cc.adfa.oz.au!newshost.carno.net.au!harbinger.cc.monash.edu.au!news.mel.connect.com.au!munnari.OZ.AU!news.ecn.uoknor.edu!feed1.news.erols.com!howland.erols.net!news.mathworks.com!bloom-beacon.mit.edu!cambridge-news.cygnus.com!not-for-mail From: meissner@cygnus.com (Michael Meissner) Newsgroups: comp.unix.solaris,comp.unix.bsd.misc,comp.unix.internals Subject: Re: Solaris 2.6 Date: 13 Dec 1996 10:27:25 -0500 Organization: Cygnus Support Lines: 17 Distribution: inet Message-ID: <sy9172tqg2.fsf@tiktok.cygnus.com> References: <32986299.AC7@mail.esrin.esa.it> <casper.329d5a07@mail.fwi.uva.nl> <5869r2$175$1@asgard.sprintlink.co.za> <587mc1$1dc@cucumber.demon.co.uk> <589rd5$i2l@agate.berkeley.edu> <sylob50vto.fsf@tiktok.cygnus.com> <casper.32afd1f6@mail.fwi.uva.nl> NNTP-Posting-Host: tiktok.cygnus.com In-reply-to: casper@fwi.uva.nl's message of 12 Dec 1996 10:35:51 +0100 X-Newsreader: Gnus v5.1 Xref: euryale.cc.adfa.oz.au comp.unix.solaris:92470 comp.unix.bsd.misc:1813 comp.unix.internals:11614 In article <casper.32afd1f6@mail.fwi.uva.nl> casper@fwi.uva.nl (Casper H.S. Dik) writes: | But all pointers can be cast to void * and back, right? So %p can be | used portably. | | (Yep, I've worked on systems where pointer casts did change the | bit pattern) All pointers to data can be cast to void * (the point I was making was that you do have to do the cast). Under strict ISO C, it is not possible to convert a function or a function pointer to void * and vice versa, except for converting (void *)0 to the appropriate function pointer. -- Michael Meissner, Cygnus Support (East Coast) 4th floor, 955 Massachusetts Avenue, Cambridge, MA 02139, USA meissner@cygnus.com, 617-354-5416 (office), 617-354-7161 (fax)