From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 29527 invoked by alias); 13 Mar 2014 15:14:50 -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 29515 invoked by uid 89); 13 Mar 2014 15:14:49 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.9 required=5.0 tests=AWL,BAYES_00,SPF_HELO_PASS,SPF_PASS,T_RP_MATCHES_RCVD autolearn=ham version=3.3.2 X-HELO: mx1.redhat.com Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Thu, 13 Mar 2014 15:14:48 +0000 Received: from int-mx02.intmail.prod.int.phx2.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id s2DFEi1d031628 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Thu, 13 Mar 2014 11:14:44 -0400 Received: from barimba (ovpn-113-169.phx2.redhat.com [10.3.113.169]) by int-mx02.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id s2DFEgQB021383 (version=TLSv1/SSLv3 cipher=AES128-SHA bits=128 verify=NO); Thu, 13 Mar 2014 11:14:43 -0400 From: Tom Tromey To: Yao Qi Cc: Subject: Re: [PATCH 0/5] Return error code in get_number References: <1394677950-4054-1-git-send-email-yao@codesourcery.com> Date: Thu, 13 Mar 2014 15:14:00 -0000 In-Reply-To: <1394677950-4054-1-git-send-email-yao@codesourcery.com> (Yao Qi's message of "Thu, 13 Mar 2014 10:32:25 +0800") Message-ID: <87d2hqku59.fsf@fleche.redhat.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-SW-Source: 2014-03/txt/msg00315.txt.bz2 >>>>> "Yao" == Yao Qi writes: Yao> Patch #5 tries to teach GDB to accept convenience variable in MI Yao> commands, in which we use get_number to parse string and get number. Yao> However, get_number returns zero for any kinds of error, and callers Yao> can't tell from it. Patch #4 changes get_number's interface to Yao> return parsing status and parsed number. This patch also moves Yao> some printing messages out of get_number, and let the callers to Yao> print messages according to returned status. Could you say what you want this for? I don't understand why an MI client would ever use it. Tom