Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:50882 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 82236 invoked from network); 7 Dec 2010 00:33:14 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 7 Dec 2010 00:33:14 -0000 Authentication-Results: pb1.pair.com smtp.mail=mozo@mozo.jp; spf=permerror; sender-id=permerror Authentication-Results: pb1.pair.com header.from=mozo@mozo.jp; sender-id=permerror Received-SPF: error (pb1.pair.com: domain mozo.jp from 209.85.161.42 cause and error) X-PHP-List-Original-Sender: mozo@mozo.jp X-Host-Fingerprint: 209.85.161.42 mail-fx0-f42.google.com Received: from [209.85.161.42] ([209.85.161.42:50947] helo=mail-fx0-f42.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 0E/63-59654-8C08DFC4 for ; Mon, 06 Dec 2010 19:33:13 -0500 Received: by fxm11 with SMTP id 11so10414732fxm.29 for ; Mon, 06 Dec 2010 16:33:08 -0800 (PST) Received: by 10.223.85.197 with SMTP id p5mr3119812fal.65.1291681988768; Mon, 06 Dec 2010 16:33:08 -0800 (PST) MIME-Version: 1.0 Received: by 10.223.78.140 with HTTP; Mon, 6 Dec 2010 16:32:48 -0800 (PST) In-Reply-To: <4CFD4E2B.5080108@zend.com> References: <4CE537B0.1030607@zend.com> <4CFCBFBB.5000901@zend.com> <4CFD4E2B.5080108@zend.com> Date: Tue, 7 Dec 2010 09:32:48 +0900 Message-ID: To: Dmitry Stogov Cc: PHP Internals , Andi Gutmans , Zeev Suraski Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Subject: Re: --enable-zend-multibyte From: mozo@mozo.jp (Moriyoshi Koizumi) On Tue, Dec 7, 2010 at 5:57 AM, Dmitry Stogov wrote: > On 12/06/2010 08:25 PM, Moriyoshi Koizumi wrote: >> >> On Mon, Dec 6, 2010 at 7:49 PM, Dmitry Stogov =A0wrote: >>> >>> Hi Moriyoshi, >>> >>> On 12/06/2010 01:31 PM, Moriyoshi Koizumi wrote: >>>> >>>> Hi, >>>> >>>> How about using the value of mbstring.script_encoding to determine >>>> whether to enable the encoding conversion feature? =A0If the value is >>>> the same as that of mbstring.internal_encoding, then no conversion >>>> should be needed in the first place. =A0Besides we can define some >>>> singular value like "none" that completely disables the conversion. >>> >>> Right now I introduced zend.multibyte directive which enables to look >>> into >>> mbstring.script_encoding and mbstring.internal_encoding as it did befor= e >>> with --enable-zend-multibyte. Note that we can't check for them in ZE >>> directly because ZE knows nothing about ext/mbstring. It may be not >>> compiled >>> into PHP or compiled as DSO. Probably it's possible to do through >>> additional >>> callbacks. >> >> Indeed mbstring.script_encoding is only used by zend_multibyte, so it >> would make sense to alter the name of the ini setting to something >> like zend.script_encoding, and move the relevant part of mbstring.c >> into zend_multibyte.c >> > > Usage of zend.script_encoding instead of zend.multibyte might make sense. > I'll take a look into it. However I don't see a way to move "the relevant > parts" of ext/mbstring into zend_multibute.c. zend_multibyte will have to > call for external detector and converter anyway. May be I misunderstood y= ou. > Could you explain what you means? I meant the part only related to the ini setting. Related part in mb_get_info() can be removed as it would no longer belong to mbstring settings. While I am not sure of what you meant by external detector and converter, encoding detector would be supplied through zend_multibyte_set_functions() in mbstring's MINIT and there should be no need to bring any extra facility into zend_multibyte.c . Regards, Moriyoshi > Thanks. Dmitry. > > Thanks. Dmitry. > > >