Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:54717 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 46534 invoked from network); 19 Aug 2011 11:15:27 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 19 Aug 2011 11:15:27 -0000 Authentication-Results: pb1.pair.com header.from=jbondc@openmv.com; sender-id=unknown Authentication-Results: pb1.pair.com smtp.mail=jbondc@openmv.com; spf=permerror; sender-id=unknown Received-SPF: error (pb1.pair.com: domain openmv.com from 64.15.152.204 cause and error) X-PHP-List-Original-Sender: jbondc@openmv.com X-Host-Fingerprint: 64.15.152.204 mail.ca.gdesolutions.com Received: from [64.15.152.204] ([64.15.152.204:52821] helo=mail.ca.gdesolutions.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 88/F6-11562-EC54E4E4 for ; Fri, 19 Aug 2011 07:15:26 -0400 Received: from localhost (localhost [127.0.0.1]) by mail.ca.gdesolutions.com (Postfix) with ESMTP id B32D45DA0; Fri, 19 Aug 2011 07:15:23 -0400 (EDT) X-Virus-Scanned: amavisd-new at gdesolutions.com Received: from mail.ca.gdesolutions.com ([127.0.0.1]) by localhost (mail.ca.gdesolutions.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id fkIbAUNlhJZC; Fri, 19 Aug 2011 07:15:22 -0400 (EDT) Received: from djbondc (modemcable166.116-70-69.static.videotron.ca [69.70.116.166]) by mail.ca.gdesolutions.com (Postfix) with ESMTPSA id C42345D9F; Fri, 19 Aug 2011 07:15:22 -0400 (EDT) To: "'Kingsquare.nl - Robin Speekenbrink'" , References: <4E4D4B8D.6090406@sugarcrm.com> <4E4E1561.8070305@kingsquare.nl> In-Reply-To: <4E4E1561.8070305@kingsquare.nl> Date: Fri, 19 Aug 2011 07:15:22 -0400 Message-ID: <006f01cc5e61$49b72600$dd257200$@com> MIME-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Mailer: Microsoft Office Outlook 12.0 thread-index: AcxeRIk6wrMqoDG0R/CRFNN26vaYoQAFk/dA Content-Language: en-ca Subject: RE: [PHP-DEV] Activation of IGBinary serialization extension in 5.4 by default From: jbondc@openmv.com ("Jonathan Bond-Caron") On Fri Aug 19 03:48 AM, Kingsquare.nl - Robin Speekenbrink wrote: >=20 > Also the proposed include it -> read the data -> convert on write if=20 > in previous format (possibly an ini setting?) would provide full BC=20 > and would allow a painless upgrade... wouldnt it? >=20 100% against enabling it by default.=20 - still a BC break since some apps in the wild assume serialize($foo) is = ascii text (whether that's good or bad). - the default serialize() is readable, easy to debug, doesn't assume you = can read binary. PHP is also about simplicity not performance. - igbinary_serialize_double() is not cross-platform so = serializing/unserializing a 'float' won't always work http://www.dmh2000.com/cpp/dswap.shtml (2. use a 'union' type to overlay = a byte array on top of the data) My preference would be to have: serialize_text() -- ascii text only (standard/var.c) but remove = 'NULL' byte (working on a patch for this) serialize_binary() -- igbinary bundled into core... serialize() -- based on php.ini setting, serialize_text by = default