From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 2702 invoked by alias); 24 May 2005 17:17:55 -0000 Mailing-List: contact gcc-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-owner@gcc.gnu.org Received: (qmail 2341 invoked by uid 22791); 24 May 2005 17:17:47 -0000 Received: from mail-out4.apple.com (HELO mail-out4.apple.com) (17.254.13.23) by sourceware.org (qpsmtpd/0.30-dev) with ESMTP; Tue, 24 May 2005 17:17:47 +0000 Received: from mailgate1.apple.com (a17-128-100-225.apple.com [17.128.100.225]) by mail-out4.apple.com (8.12.11/8.12.11) with ESMTP id j4OHHjCX029827 for ; Tue, 24 May 2005 10:17:45 -0700 (PDT) Received: from relay1.apple.com (relay1.apple.com) by mailgate1.apple.com (Content Technologies SMTPRS 4.3.17) with ESMTP id ; Tue, 24 May 2005 10:17:45 -0700 Received: from [17.201.20.185] (johada5.apple.com [17.201.20.185]) by relay1.apple.com (8.12.11/8.12.11) with ESMTP id j4OHHfxK004281; Tue, 24 May 2005 10:17:42 -0700 (PDT) In-Reply-To: <20050524164346.GA15215@synopsys.com> References: <1116907280.9577.31.camel@localhost.localdomain> <87br71kv04.fsf@codesourcery.com> <17043.14455.575632.115175@gargle.gargle.HOWL> <20050524164346.GA15215@synopsys.com> Mime-Version: 1.0 (Apple Message framework v622) Content-Type: text/plain; charset=US-ASCII; format=flowed Message-Id: <64dff9f798629247ad913b55c1a227bd@apple.com> Content-Transfer-Encoding: 7bit Cc: Dale Johannesen , gdr@integrable-solutions.net, Paul Koning , gcc@gcc.gnu.org, Andreas Schwab , zack@codesourcery.com, mark@codesourcery.com, jason@redhat.com, dberlin@dberlin.org From: Dale Johannesen Subject: Re: Compiling GCC with g++: a report Date: Tue, 24 May 2005 21:40:00 -0000 To: Joe Buck X-SW-Source: 2005-05/txt/msg01308.txt.bz2 On May 24, 2005, at 9:43 AM, Joe Buck wrote: > On Tue, May 24, 2005 at 05:03:27PM +0200, Andreas Schwab wrote: >> Paul Koning writes: >>> I hope that doesn't require (void *) casts for pointer arguments >>> passed to the likes of memcpy... >> >> Only the (void*) -> (any*) direction requires a cast in C++, the other >> direction is still converted implicitly. > > For this reason, I always cast the result of malloc to the proper type; > it just feels wrong otherwise. Yes, if the cast looks odd to you, you probably don't go back far enough. I've certainly used compilers that warned when you didn't have a cast there.