From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 16289 invoked by alias); 1 Dec 2004 17:57:26 -0000 Mailing-List: contact gcc-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-owner@gcc.gnu.org Received: (qmail 16130 invoked from network); 1 Dec 2004 17:56:59 -0000 Received: from unknown (HELO Cantor.suse.de) (195.135.220.2) by sourceware.org with SMTP; 1 Dec 2004 17:56:59 -0000 Received: from hermes.suse.de (hermes-ext.suse.de [195.135.221.8]) (using TLSv1 with cipher EDH-RSA-DES-CBC3-SHA (168/168 bits)) (No client certificate requested) by Cantor.suse.de (Postfix) with ESMTP id CEFCE11A4CFB; Wed, 1 Dec 2004 18:56:58 +0100 (CET) Message-ID: <41AE0633.2050402@suse.de> Date: Wed, 01 Dec 2004 17:57:00 -0000 From: Paolo Carlini User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.3) Gecko/20040913 MIME-Version: 1.0 To: Nick NoSpam Cc: gcc@gcc.gnu.org Subject: Re: Making strings of arbitrary character types References: <1101893017.30862.7.camel@nimble.325Bayport> <41AD9189.9010503@suse.de> <1101895684.30829.18.camel@nimble.325Bayport> <1101896214.30811.26.camel@nimble.325Bayport> <41AD9B4F.2040405@suse.de> <1101917796.21171.5.camel@nimble.325Bayport> In-Reply-To: <1101917796.21171.5.camel@nimble.325Bayport> X-Enigmail-Version: 0.89.0.0 X-Enigmail-Supports: pgp-inline, pgp-mime Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-SW-Source: 2004-12/txt/msg00071.txt.bz2 Nick NoSpam wrote: >On Wed, 2004-12-01 at 11:22 +0100, Paolo Carlini wrote: > > >>Right, 3.4.x is vastly better in this area (and we don't have any open >>bug ;) >> >> >I hope this isn't the first. > No, it isn't ;) You have to prepare a suited codecvt facet, able to convert during I/O from/to you internal ("in memory") type (unsigned char) to the external ("on disk") type (char): unfortunately, there is no such as thing as a "general" codecvt... I suggest taking inspiration from the snippet present in our testsuite, in particular: testsuite/27_io/basic_filebuf/seekoff/wchar_t/12790*.cc + testsuite_character.h Paolo.