Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP
Posting-Version: version B 2.10.1 6/24/83 (MC840302); site mcvax.UUCP
Path: utzoo!watmath!clyde!burl!ulysses!harpo!decvax!mcvax!guido
From: guido@mcvax.UUCP (Guido van Rossum)
Newsgroups: net.lang.c
Subject: Is mixing char and int types as parameters portable?
Message-ID: <5734@mcvax.UUCP>
Date: Wed, 14-Mar-84 07:57:16 EST
Article-I.D.: mcvax.5734
Posted: Wed Mar 14 07:57:16 1984
Date-Received: Thu, 15-Mar-84 07:15:33 EST
Organization: CWI, Amsterdam
Lines: 17

I'd like to hear the opinion of the net on the following (MAIL please;
I'll summarize):

The K&R book says that chars are widened to ints before anything is
done to them (except when used as lvalue, I think).  Does this mean
that the following code is portable, even to the weirdest machines?

	foo(c) char c; { ... }

	bar(i) int i; { ... }

	main() { foo(100); bar(' '); }

(Please, no guesses -- I can GUESS it's right myself.)

	Guido van Rossum, CWI, Amsterdam     guido@mcvax