From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 14113 invoked by alias); 31 Aug 2004 12:53:21 -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 14068 invoked from network); 31 Aug 2004 12:53:17 -0000 Received: from unknown (HELO polimi.it) (131.175.12.8) by sourceware.org with SMTP; 31 Aug 2004 12:53:17 -0000 Received: from gnu.org (paride.rett.polimi.it [131.175.65.135]) by polimi.it (8.13.1/8.13.1) with ESMTP id i7VCrFDA016488; Tue, 31 Aug 2004 14:53:16 +0200 Message-ID: <413475EE.6000502@gnu.org> Date: Tue, 31 Aug 2004 13:03:00 -0000 From: Paolo Bonzini User-Agent: Mozilla Thunderbird 0.5 (Windows/20040207) MIME-Version: 1.0 To: kartick Vaddadi , GCC Development Subject: Re: automatic casting References: <20040831124904.71199.qmail@web20424.mail.yahoo.com> In-Reply-To: <20040831124904.71199.qmail@web20424.mail.yahoo.com> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-PMX-Version: 4.6.1.107272, Antispam-Core: 4.6.1.106808, Antispam-Data: 2004.8.30.111598 X-PerlMx-Spam: Gauge=%%XPROB%%IIIIIII, Probability=7%, Report='__MOZILLA_MSGID 0, __HAS_MSGID 0, __SANE_MSGID 0, __USER_AGENT 0, X_ACCEPT_LANG 0, __MIME_VERSION 0, __TO_MALFORMED_2 0, __REFERENCES 0, __IN_REP_TO 0, __EVITE_CTYPE 0, __CT_TEXT_PLAIN 0, __CT 0, __CTE 0, __MIME_TEXT_ONLY 0, REFERENCES 0.000, IN_REP_TO 0, USER_AGENT 0.000' X-SW-Source: 2004-08/txt/msg01613.txt.bz2 > why not eliminate the requirement to cast, since the > instanceof ensures that the object is of the right You should ask Sun about this, not the GCC community; there are no GNU extensions to the Java language. Anyway the answer is probably going to be that while this case is obvious, there are going to be more and more complicated cases that the compiler won't possibly figure out. Paolo