Path: utzoo!utgpu!water!watmath!clyde!att!osu-cis!tut.cis.ohio-state.edu!mailrus!ames!oliveb!sun!thetone!swilson From: swilson%thetone@Sun.COM (Scott Wilson) Newsgroups: comp.lang.c Subject: Re: `char' parameters Keywords: parameter, K&R, ANSI C Message-ID: <66530@sun.uucp> Date: 1 Sep 88 06:39:17 GMT References: <1616@se-sd.sandiego.ncr.com> Sender: news@sun.uucp Reply-To: swilson@sun.UUCP (Scott Wilson) Organization: Sun Microsystems, Mountain View Lines: 23 >I was aware of what happens to the <>. >The passage does not explain, however, what happens when one declares the >parameter to be type `char' or `float'; I don't see this prohibited >anywhere. I was bitten by the float/double version of this once. I had declared a formal parameter as a float, took its address and passed what I thought was a float pointer to another function. Anyway, I don't have K&R 2nd edition around, but K&R 1st edition does describe float formal arguments. From page 205: C converts all float actual parameters to double, so formal parameters declared float have their declaration adjusted to read double. Your're right though, that int vs. char is not explicitly mentioned in this section. -- Scott Wilson arpa: swilson@sun.com Sun Microsystems uucp: ...!sun!swilson Mt. View, CA