From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 31555 invoked by alias); 29 Jan 2008 16:34:43 -0000 Received: (qmail 31544 invoked by uid 22791); 29 Jan 2008 16:34:43 -0000 X-Spam-Check-By: sourceware.org Received: from NaN.false.org (HELO nan.false.org) (208.75.86.248) by sourceware.org (qpsmtpd/0.31) with ESMTP; Tue, 29 Jan 2008 16:34:23 +0000 Received: from nan.false.org (localhost [127.0.0.1]) by nan.false.org (Postfix) with ESMTP id 0B3C998151; Tue, 29 Jan 2008 16:34:22 +0000 (GMT) Received: from caradoc.them.org (22.svnf5.xdsl.nauticom.net [209.195.183.55]) by nan.false.org (Postfix) with ESMTP id D935C9811F; Tue, 29 Jan 2008 16:34:21 +0000 (GMT) Received: from drow by caradoc.them.org with local (Exim 4.68) (envelope-from ) id 1JJtPh-0000DK-0T; Tue, 29 Jan 2008 11:34:21 -0500 Date: Tue, 29 Jan 2008 16:37:00 -0000 From: Daniel Jacobowitz To: Doug Evans Cc: GDB Patches , Pierre Muller Subject: Re: [BUG] BINOP_DIV and ptyp command Message-ID: <20080129163420.GB32558@caradoc.them.org> Mail-Followup-To: Doug Evans , GDB Patches , Pierre Muller References: <002301c85c12$a73a4640$f5aed2c0$@u-strasbg.fr> <20080129134609.GB22342@caradoc.them.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.17 (2007-12-11) X-IsSubscribed: yes Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2008-01/txt/msg00686.txt.bz2 I would prefer that we not make type promotion more wrong, so I would rather not apply your patch until the standard promotions do something more sensible. On Tue, Jan 29, 2008 at 08:20:07AM -0800, Doug Evans wrote: > For completeness' sake, while my pedantic bit is flipped, > One premise of this particular comment is that it assumes one > particular definition of EVAL_AVOID_SIDE_EFFECTS. If E_A_S_E is > indeed intended to mean to avoid calling error() (which isn't > unreasonable), then that changes the premise. > > To make progress here (and those who have worked on gdb longer > probably know the complete definition of E_A_S_E already - they take > it as a given - I can't) it would be nice to at least have a full and > correct definition of EVAL_AVOID_SIDE_EFFECTS at its definition site. Either there's no complete definition of the type you want, or it was lost before I began working on GDB. We need to set one. EVAL_AVOID_SIDE_EFFECTS is checked in many places, but only set in a few: evaluate_type, to check for user defined operators in short-circuit expressions, and sizeof. evaluate_type is only used for whatis (ptype), maint print type, and the error case for varobjs. I think that avoiding value-dependent calls to error, when practical, is more useful in all of those cases. One way to do it would be to pass noside further down; but that changes all call sites. -- Daniel Jacobowitz CodeSourcery