Message-Id: <3.0.5.32.19980829131459.007c13f0@200.252.238.1> Date: Sat, 29 Aug 1998 13:14:59 -0300 To: djgpp AT delorie DOT com From: "Thiago F.G. Albuquerque" Subject: Re: 2 quick questions In-Reply-To: <35e75646.2796107@cnews.newsguy.com> References: <35D4F001 DOT 4A3E2B2D AT xyz DOT net> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Precedence: bulk At 01:22 29/08/98 GMT, you wrote: >On Fri, 14 Aug 1998 18:18:41 -0800, Bjorn Hansen >wrote: > >>1] what does the exit code tell you? >> >>2] why does the compiler have a warning message if you don't use a >>caste? when you do something like this >> >>int i; >>int *ip; >>ip=i; >> >>instead of this >> >>int i; >>int *ip; >>ip=(int *)i; >> >> >>Bjorn Hansen The correct code would be: int i; int *ip; ip=&i; Use the 'address-of' operator (&) to tell the compiler that what you want in ip is the *adress* of 'i', not the contents 'i' itself. [], Thiago