From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 20405 invoked by alias); 17 Mar 2019 23:41:32 -0000 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 Received: (qmail 20392 invoked by uid 89); 17 Mar 2019 23:41:31 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-1.9 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_NONE,SPF_PASS autolearn=ham version=3.3.1 spammy=H*r:192.168.0, HX-Languages-Length:798, tomorrow X-HELO: mail-wr1-f66.google.com Received: from mail-wr1-f66.google.com (HELO mail-wr1-f66.google.com) (209.85.221.66) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Sun, 17 Mar 2019 23:41:30 +0000 Received: by mail-wr1-f66.google.com with SMTP id w2so15029097wrt.11 for ; Sun, 17 Mar 2019 16:41:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=undo-io.20150623.gappssmtp.com; s=20150623; h=from:content-transfer-encoding:mime-version:subject:date:references :to:in-reply-to:message-id; bh=mAJ1yT2+J2CyXddGpLweshAOnTmIMimTFIlML230lI0=; b=0FJ7NFKz8Js7JvSC+blYBGrkAkGIaKBvncsqsVaLVK4oIdtZacoIMLEOr8SIOaosFa 5xG0UGNHGXpa+/rqFC0aURxrCVVuuuAEX3AThU0BxYMy3hcDIlRnAABjCPS7vAtGMtKx f92W+n3gTdxoyRT9u1EsP/wew/7jIv9LhE4LJPpHVMcathPOss/mBFIxjTJ5i/e0FwhL FuMmIuHo6VvLRwXNLnSVfot4ncyJ1Tg1kA4npKO7XOGnZpyjhCubYwQapc0LqXbNzLVa rDWZoGxCxPcJRg6AEI0+ecw/vky316OhsjE0KDsS68YCz+ZmI550Cdc+hgOTHR7RhmFF ZfYQ== Return-Path: Received: from [192.168.0.109] (cpc91242-cmbg18-2-0-cust276.5-4.cable.virginm.net. [82.8.129.21]) by smtp.gmail.com with ESMTPSA id z20sm10080662wma.48.2019.03.17.16.41.27 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 17 Mar 2019 16:41:27 -0700 (PDT) From: Marco Barisione Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Mime-Version: 1.0 (Mac OS X Mail 12.2 \(3445.102.3\)) Subject: Re: [PATCH] Add gdb.Value.format_string () Date: Sun, 17 Mar 2019 23:41:00 -0000 References: <20190317135023.2e51944d@f29-4.lan> To: gdb-patches@sourceware.org In-Reply-To: <20190317135023.2e51944d@f29-4.lan> Message-Id: X-IsSubscribed: yes X-SW-Source: 2019-03/txt/msg00362.txt.bz2 > On 17 Mar 2019, at 20:50, Kevin Buettner wrote: > > Hi Marco, > > Overall, I like this patch. See below for my comments. Thanks! I will fix your review comments tomorrow. >> +/* Given a Python object, copy its truth value to a C int (the value >> + pointed by dest). >> + If src_obj is NULL, then *dest is not modified. >> + >> + Return 1 in case of success, -1 otherwise. */ > > Why not use a bool return type to indicate success or failure? Because I was under the mistaken impression that this was the style for GDB code, at least by looking at py-value.c and the other couple of files I checked. (To be fair, the other functions in this file return 1, 0 and -1 for errors, not just two values like mine.) -- Marco Barisione