Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:60579 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 81175 invoked from network); 14 May 2012 13:41:31 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 14 May 2012 13:41:31 -0000 Authentication-Results: pb1.pair.com header.from=dragoonis@gmail.com; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=dragoonis@gmail.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 74.125.82.54 as permitted sender) X-PHP-List-Original-Sender: dragoonis@gmail.com X-Host-Fingerprint: 74.125.82.54 mail-wg0-f54.google.com Received: from [74.125.82.54] ([74.125.82.54:54542] helo=mail-wg0-f54.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id F3/96-44671-88B01BF4 for ; Mon, 14 May 2012 09:41:29 -0400 Received: by wgbfg15 with SMTP id fg15so3888844wgb.11 for ; Mon, 14 May 2012 06:41:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=xLRQYyEAfhaWrlC5iLEpf079IzN9Li5Cgf/Zbvb/yuA=; b=Ns1zUlASjqADkomjRy7uVTpFl/MmxZHFss2EvHvKwHfQN/RgmkmngyjhheRh0RuQVR nPlwyECknNTmBrrg7JynlVB0nng40Q2hVF8PrQVmam2KpbmvUGtw/ktDnU0+rIvrXQbi 1uCgN1Sxy0wzsOQNtpkVWnqbY7UG+qK3/CLL8n1V6++FGjgz1WSIPrUAqIF2/oXtuezf r0dTQyxeWHg/lEkKj+EPYkKiK9DQTtL6B3hFW3AvvGlfvoMReTKC0eSgqirrV1joZ2NN e3We1VrDk2Eqk4cadtnlJCxnqWM+hP0nWMKNOnCVcS4uXI5OW1m8hLKtE8JeLfm/g6hE b75w== MIME-Version: 1.0 Received: by 10.50.40.193 with SMTP id z1mr4301964igk.0.1337002885056; Mon, 14 May 2012 06:41:25 -0700 (PDT) Received: by 10.64.31.198 with HTTP; Mon, 14 May 2012 06:41:25 -0700 (PDT) In-Reply-To: References: Date: Mon, 14 May 2012 14:41:25 +0100 Message-ID: To: Pierre Joye Cc: Gustavo Lopes , "internals@lists.php.net" Content-Type: multipart/alternative; boundary=14dae9340c41070a6704bfff3ea8 Subject: Re: [PHP-DEV] [RFC] [DISCUSSION] array_part() From: dragoonis@gmail.com (Paul Dragoonis) --14dae9340c41070a6704bfff3ea8 Content-Type: text/plain; charset=ISO-8859-1 On Mon, May 14, 2012 at 2:01 PM, Pierre Joye wrote: > hi Gustavo, > > I would add some examples inline in the RFC, with explanation, to ease > the comprehension of this new function and its possibility. The > current RFC is somehow hard to digest :) > Yes, that's what I was meaning earlier but was on my mobile phone. Thanks Pierre. Gustavo, why would I use array_part() if I could use array_slice() to get the parts of an array between two offsets. > > > Cheers, > > On Mon, May 14, 2012 at 1:39 PM, Gustavo Lopes > wrote: > > On Mon, 14 May 2012 13:23:27 +0200, Paul Dragoonis > > wrote: > > > >> Am i correct in assuming this is basically substr() for arrays. > > > > > > No. That's a part of it. It also does indexes as keys (like array_slice) > and > > multidimensional arrays, none of which have anything analogous in > strings. > > > > > > -- > > Gustavo Lopes > > > > -- > > PHP Internals - PHP Runtime Development Mailing List > > To unsubscribe, visit: http://www.php.net/unsub.php > > > > > > -- > Pierre > > @pierrejoye | http://blog.thepimp.net | http://www.libgd.org > --14dae9340c41070a6704bfff3ea8--