From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 27826 invoked by alias); 13 Apr 2006 17:31:23 -0000 Received: (qmail 27818 invoked by uid 22791); 13 Apr 2006 17:31:23 -0000 X-Spam-Check-By: sourceware.org Received: from xproxy.gmail.com (HELO xproxy.gmail.com) (66.249.82.196) by sourceware.org (qpsmtpd/0.31) with ESMTP; Thu, 13 Apr 2006 17:31:21 +0000 Received: by xproxy.gmail.com with SMTP id h29so1177177wxd for ; Thu, 13 Apr 2006 10:31:19 -0700 (PDT) Received: by 10.70.111.3 with SMTP id j3mr950594wxc; Thu, 13 Apr 2006 10:31:18 -0700 (PDT) Received: by 10.70.125.5 with HTTP; Thu, 13 Apr 2006 10:31:18 -0700 (PDT) Message-ID: <8f2776cb0604131031g370d6fa9p9361421bd21d178@mail.gmail.com> Date: Thu, 13 Apr 2006 18:06:00 -0000 From: "Jim Blandy" To: "Vladimir Prus" Subject: Re: printing wchar_t* Cc: gdb@sources.redhat.com In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline References: X-IsSubscribed: yes Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2006-04/txt/msg00163.txt.bz2 On 4/13/06, Vladimir Prus wrote: > I have a user-defined command that can produce the output I want, but is > defining a custom command the right approach? Well, you'd like wide strings to be printed properly when they appear in structures, as arguments to functions, and so on, right? So a user-defined command isn't ideal. The best approach would be to extend charset.[ch] to handle wide character sets as well, and then add code to the language-specific printing routines to use the charset functions. (This is fortunately much simpler than adding support for multibyte characters.)