From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 13397 invoked by alias); 5 Feb 2009 13:19:14 -0000 Received: (qmail 13381 invoked by uid 22791); 5 Feb 2009 13:19:13 -0000 X-SWARE-Spam-Status: No, hits=-2.7 required=5.0 tests=AWL,BAYES_00,SPF_PASS X-Spam-Check-By: sourceware.org Received: from e24smtp02.br.ibm.com (HELO e24smtp02.br.ibm.com) (32.104.18.86) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Thu, 05 Feb 2009 13:19:10 +0000 Received: from d24relay01.br.ibm.com (d24relay01.br.ibm.com [9.8.31.16]) by e24smtp02.br.ibm.com (8.13.1/8.13.1) with ESMTP id n15DQOAH014358 for ; Thu, 5 Feb 2009 11:26:24 -0200 Received: from d24av01.br.ibm.com (d24av01.br.ibm.com [9.18.232.46]) by d24relay01.br.ibm.com (8.13.8/8.13.8/NCO v9.1) with ESMTP id n15EIYdk3739894 for ; Thu, 5 Feb 2009 11:18:34 -0300 Received: from d24av01.br.ibm.com (loopback [127.0.0.1]) by d24av01.br.ibm.com (8.12.11.20060308/8.13.3) with ESMTP id n15DJ5xk011985 for ; Thu, 5 Feb 2009 11:19:06 -0200 Received: from [9.18.201.230] ([9.18.201.230]) by d24av01.br.ibm.com (8.12.11.20060308/8.12.11) with ESMTP id n15DJ5J4011976; Thu, 5 Feb 2009 11:19:05 -0200 Subject: Re: [RFA][python] Add gdb.Value.string method. From: Thiago Jung Bauermann To: tromey@redhat.com Cc: Eli Zaretskii , gdb-patches@sourceware.org In-Reply-To: References: <1230949647.8380.145.camel@localhost.localdomain> <1233669417.14735.14.camel@localhost.localdomain> Content-Type: text/plain; charset=utf-8 Date: Thu, 05 Feb 2009 13:19:00 -0000 Message-Id: <1233839944.14735.72.camel@localhost.localdomain> Mime-Version: 1.0 Content-Transfer-Encoding: 8bit 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: 2009-02/txt/msg00120.txt.bz2 El mié, 04-02-2009 a las 12:45 -0700, Tom Tromey escribió: > >>>>> "Eli" == Eli Zaretskii writes: > > >> > +If the optional @var{encoding} argument is given, it must be a string > >> > +naming the encoding of the string in the @code{gdb.Value}. > > Eli> Would every Python programmer know what kind of argument strings can > Eli> be given for @var{encoding}? If not, perhaps a list or at least a > Eli> hint where to find such a list would be useful. > > We can't list the possible encodings -- not only does the list change > over time, but users can write their own codecs in Python. > > I suggest just hoisting the reference to Python's "string.decode" > method to an earlier spot in the paragraph. This should be sufficient > for anybody, use of the string module is common knowledge. What about the following, then? "If the optional @var{encoding} argument is given, it must be a string naming the encoding of the string in the @code{gdb.Value}. It accepts the same encodings as the corresponding argument to Python's @code{string.decode} method, so the Python codec machinery will be used to convert the string." I left the paragraph about the errors argument untouched. -- []'s Thiago Jung Bauermann IBM Linux Technology Center