From owner-freebsd-questions@FreeBSD.ORG Sat Feb 19 23:17:36 2005 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 3144316A4CE for ; Sat, 19 Feb 2005 23:17:36 +0000 (GMT) Received: from smtp11.wanadoo.fr (smtp11.wanadoo.fr [193.252.22.31]) by mx1.FreeBSD.org (Postfix) with ESMTP id D953443D3F for ; Sat, 19 Feb 2005 23:17:35 +0000 (GMT) (envelope-from atkielski.anthony@wanadoo.fr) Received: from me-wanadoo.net (localhost [127.0.0.1]) by mwinf1103.wanadoo.fr (SMTP Server) with ESMTP id 98D4C1C00084 for ; Sun, 20 Feb 2005 00:17:34 +0100 (CET) Received: from pix.atkielski.com (ASt-Lambert-111-2-1-3.w81-50.abo.wanadoo.fr [81.50.80.3]) by mwinf1103.wanadoo.fr (SMTP Server) with ESMTP id 7B70B1C00082 for ; Sun, 20 Feb 2005 00:17:34 +0100 (CET) X-ME-UUID: 20050219231734505.7B70B1C00082@mwinf1103.wanadoo.fr Date: Sun, 20 Feb 2005 00:17:31 +0100 From: Anthony Atkielski X-Priority: 3 (Normal) Message-ID: <675354920.20050220001731@wanadoo.fr> To: freebsd-questions@freebsd.org In-Reply-To: References: <5b8472dd5925a0b0b59f15cd9f8e15f3@shire.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Subject: Re: c++ X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: freebsd-questions@freebsd.org List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 19 Feb 2005 23:17:36 -0000 Gert Cuykens writes: > What does coercing mean ? Telling the compiler to disregard mismatches between data types. Normally, if you put an integer in a program where a character pointer is required, the compiler will complain. If you use a cast to coerce the type of the integer to a character pointer, the compiler will let it pass, and will treat the integer as a pointer (whether it really contains a pointer or not). > Why does the compiler have to match parameters ? To help avoid errors in coding, the compiler makes sure that the type of a variable matches what is expected in certain situations. > PS what is the difference between ? > A=*data The contents of the memory location pointed to by data is copied to A. > A=data The value of data is copied to A. > A=&data The address in memory of data is copied to A. -- Anthony