Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:61663 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 46195 invoked from network); 24 Jul 2012 08:53:10 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 24 Jul 2012 08:53:10 -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.213.42 as permitted sender) X-PHP-List-Original-Sender: julienpauli@gmail.com X-Host-Fingerprint: 209.85.213.42 mail-yw0-f42.google.com Received: from [209.85.213.42] ([209.85.213.42:52890] helo=mail-yw0-f42.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id D1/4A-17533-5726E005 for ; Tue, 24 Jul 2012 04:53:10 -0400 Received: by yhoo21 with SMTP id o21so7303759yho.29 for ; Tue, 24 Jul 2012 01:53:07 -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=3HVpT5CZSsL/rYKhFuAz2qScF8hZDGmxqM2JWXSuGgY=; b=mtQ2EZkxaogHrkhRzAwjeB+UDHheQ9SVEjEoGKXKmJsraY1dru8bWaG274mv/NiQLz Wu17SyAK9PYxsHNxiuVXvFCtIPoFbMF8Fk1wxLG0bBuM4dwS50X6nCTIRbKt2zVo5bX4 Zu4iereQp9lckcP72YEdDq3y980yTgJx+zG4v+1Yr344zQQqD6I2YEp+4im2YTcyIVHm RgqlAR8QgZUXQoB2WS3+IfEK4SWJhyp0GXfUfaQACYEE6XoMviS2AyCsBpXYqQaDJIQM 2bSVG6VHpVFQzYqVpi5Ynv3IHNb0cSpGQBTdhVy5Js5I9mneFMTWkySotdS+mpRPR/64 vwSg== Received: by 10.42.146.6 with SMTP id h6mr13529466icv.53.1343119986549; Tue, 24 Jul 2012 01:53:06 -0700 (PDT) MIME-Version: 1.0 Sender: julienpauli@gmail.com Received: by 10.64.23.74 with HTTP; Tue, 24 Jul 2012 01:52:26 -0700 (PDT) In-Reply-To: <5000BEE9.3070006@sugarcrm.com> References: <1342050547.1456.33.camel@guybrush> <4FFF6C9C.2080802@gmail.com> <36.A6.17670.8E820005@pb1.pair.com> <50005B38.3090507@sugarcrm.com> <5000BCD2.2040007@garfieldtech.com> <5000BEE9.3070006@sugarcrm.com> Date: Tue, 24 Jul 2012 10:52:26 +0200 X-Google-Sender-Auth: nVlTSgjvYjUwi4wLgQB-cEzjAgM Message-ID: To: Stas Malyshev Cc: Larry Garfield , "internals@lists.php.net" Content-Type: text/plain; charset=ISO-8859-1 Subject: Re: [PHP-DEV] Internal iteration API From: jpauli@php.net (jpauli) On Sat, Jul 14, 2012 at 2:35 AM, Stas Malyshev wrote: > Hi! > >> So, I've not been inside the engine so in practice this may make no >> sense at all, but what about looking at it the other way around? Vis, >> instead of making objects more and more like arrays, make arrays an >> object that happens to implement ArrayAccess, Iterator, and whatever > > That'd be very nice idea if we were implementing new PHP. I think the > fact that arrays are not objects in PHP is a source of many problems. > However, right now it probably won't be possible to do it without > breaking BC in many places dealing with array copy/assignment/passing > semantics. I'd then say : let's keep that idea somewhere to implement it in a new major PHP version. Anyway, there will come a time where we will be developing for PHP6 (or PHP next Major if you prefer), and I think we should use this gap to break BC and add new cool ideas like this one, we seem all to agree with. Julien.P