Path: utzoo!utgpu!jarvis.csri.toronto.edu!rutgers!apple!sun-barr!decwrl!shlump.nac.dec.com!shodha.dec.com!devine From: devine@shodha.dec.com (Bob Devine) Newsgroups: comp.lang.c Subject: Re: More NULL questions Message-ID: <448@shodha.dec.com> Date: 10 Oct 89 16:06:27 GMT References: <5950001@hpldola.HP.COM> <443@shodha.dec.com> <903@abvax.UUCP> Organization: Digital Equipment Corp. - Colorado Springs, CO. Lines: 12 In article <903@abvax.UUCP>, aep@ivan (Alex E. Pensky) writes: > Even if pointers and integers are the same size and have the same > representation, you are still in trouble if your compiler passes int > parameters and pointer parameters via different mechanisms. In such > a case, omitting both the prototype and the cast will mean that the *entire* > parameter list will be received incorrectly by my_func(). > Yes, such compilers exist, and yes, I have been bitten by one after > forgetting the casts. What different mechanisms? C only supports call-by-value for parameters (I'm ignoring the special casing of arrays here). How can pointers be passed differently than ints? It sounds like you used a broken compiler.