Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:58927 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 66444 invoked from network); 14 Mar 2012 14:53:57 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 14 Mar 2012 14:53:57 -0000 Authentication-Results: pb1.pair.com smtp.mail=julienpauli@gmail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=julienpauli@gmail.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.215.170 as permitted sender) X-PHP-List-Original-Sender: julienpauli@gmail.com X-Host-Fingerprint: 209.85.215.170 mail-ey0-f170.google.com Received: from [209.85.215.170] ([209.85.215.170:41213] helo=mail-ey0-f170.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id F6/A2-51575-401B06F4 for ; Wed, 14 Mar 2012 09:53:56 -0500 Received: by eaao10 with SMTP id o10so975535eaa.29 for ; Wed, 14 Mar 2012 07:53:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:from:date :x-google-sender-auth:message-id:subject:to:cc:content-type; bh=jYeF31s6p1kTVDvHqx7jXbHceFUL3L/hwDaXeBY+DqM=; b=iRq3DeCWmUOtLQ7yHtslo1QzHwI1o4yKZ522pQbi+kANMLIqg5enW2tNqjUoy/kuCD WMpvl3ckR9kHirxkr5DW5dfYuRtAPdtIlrbSaqn6HHJIEAf3N3Zobj4GUu2I6U9uOOUZ 0368CbQr0Xry1tXNUEelgYerl6KqrNSifUnjz2gKZ0VqJst7ATfSrPAMX4FTeSp+5tiT SAWzx/GB4Sdr2PIX1wKrHrtVhn1US70JCatGi5/ZEJ9syWLMB26qCmB/d2TRUgRLD/fA 5LYxNunKXXgbA/U21w9dxLE3FQEyOt3kGsQtZLlJOxbsJkQW1mmYC3Ux10cqRG1H36Vz 3eLQ== Received: by 10.14.202.200 with SMTP id d48mr429136eeo.44.1331736833344; Wed, 14 Mar 2012 07:53:53 -0700 (PDT) MIME-Version: 1.0 Sender: julienpauli@gmail.com Received: by 10.213.15.196 with HTTP; Wed, 14 Mar 2012 07:53:13 -0700 (PDT) In-Reply-To: References: <4F5D9C77.3030000@lerdorf.com> <4F5DA152.10109@sugarcrm.com> <4F5DA894.8060606@lerdorf.com> <4F5DAB49.3030808@sugarcrm.com> <4F5DAFCE.8020600@lerdorf.com> <4F5E15D6.6080302@lerdorf.com> Date: Wed, 14 Mar 2012 15:53:13 +0100 X-Google-Sender-Auth: NgEHvCv-qNIr_hKSmUy4zqLbBJI Message-ID: To: Gustavo Lopes Cc: "internals@lists.php.net" Content-Type: multipart/alternative; boundary=047d7b343ae4e2c4b504bb35249a Subject: Re: [PHP-DEV] default charset confusion From: jpauli@php.net (jpauli) --047d7b343ae4e2c4b504bb35249a Content-Type: text/plain; charset=ISO-8859-1 On Wed, Mar 14, 2012 at 3:37 PM, Gustavo Lopes wrote: > On Wed, 14 Mar 2012 14:55:17 +0100, jpauli wrote: > > I would then propose to make mbstring compile time mandatory. >> >> > I'm completely against these kind of lazy solutions. Yes, let's add strong > coupling (already starting to smell) to one of the largest extensions and > make it compile time mandatory because it simplifies the implementation of > a dubiously useful feature like Zend multibyte. Remember PHP is sometimes > used in environments with limited memory/disk space. > > Also mbstring takes a long time to build (relatively speaking). Just that > would be a strong argument against making it mandatory, at least for people > like me that compile PHP with --disable-all very frequently. > > > I'm against yet another global ini setting, I find the actual ini >> settings confusing enough to add one more that would moreover reflect >> mbstring one's (and add more and more confusion). >> Why not turn ext/mbstring mandatory at compile time, for all future PHP >> versions, like preg or spl are ? >> >> We do need multibyte handling either. ZendEngine takes advantage of >> mbstring for internal encoding as well, so I probably missed something as >> why it is still possible to --disable-mbstring (or not add >> --enable-mbstring) when compiling ? Has it a huge performance impact ? >> >> > mbstring hooks to basically all phases of PHP process/request > startup/shutdown. Some efforts were made to mitigate the impact of this in > 5.4 (see e.g. r301068), but at least some impact is inevitable. Of course, > if you start enabling certain features of mbstring (zend multibyte hooks, > translation of input variables, function overload) then it starts to be > significant. However, there are other more compelling reasons not to make > it required (see above). > > -- > Gustavo Lopes > That makes sense to me :-) But we should think about complexity in the final choice. Having something like "internal_encoding" adding in PHP.ini will confuse people, at least, if we dont clearly explain them what the setting is for. The name is nearly the same as mbstring's. I recently opened a doc bug about multibyte handling in 5.4 (#61373) , as the documentation is really light on that point Julien.P --047d7b343ae4e2c4b504bb35249a--