Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:66919 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 82343 invoked from network); 3 Apr 2013 16:50:14 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 3 Apr 2013 16:50:14 -0000 Authentication-Results: pb1.pair.com smtp.mail=php@golemon.com; spf=softfail; sender-id=softfail Authentication-Results: pb1.pair.com header.from=php@golemon.com; sender-id=softfail Received-SPF: softfail (pb1.pair.com: domain golemon.com does not designate 209.85.192.172 as permitted sender) X-PHP-List-Original-Sender: php@golemon.com X-Host-Fingerprint: 209.85.192.172 mail-pd0-f172.google.com Received: from [209.85.192.172] ([209.85.192.172:62650] helo=mail-pd0-f172.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id DB/F3-07534-5CD5C515 for ; Wed, 03 Apr 2013 11:50:13 -0500 Received: by mail-pd0-f172.google.com with SMTP id 5so951858pdd.3 for ; Wed, 03 Apr 2013 09:50:10 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:x-received:sender:x-originating-ip:in-reply-to :references:date:x-google-sender-auth:message-id:subject:from:to:cc :content-type:x-gm-message-state; bh=jK8UpyWvEoTe0lYAnDy5siI6BIBtjUQ2SyUXyb/v0PY=; b=Dgkb/YQnSBnOig/B0QLdxVCMKBP9QIXMCuzgQ1nnIh8rc00ZEkh3jUKfcHwsXWGk9Z GCWMupM3t+XsPq4Otw8oH0SrxiKPOmS7WELu6OLhVRfpAdZ8fqbprWhNy1IxgznxoU3Y v+Rd20R8qcS8UO2ZGknGvbfkPYTKbLWrkpL9PbEnIgAiNcFcHjjbimBaFdpvzD1BcGGD LQyAgynaQONpSTVvgK95Hf6SCs81s4y3ZjongfGy+k4/54tD5lm91fgCbDzVhHLHg039 oAkCD/g/E0BExQnbROyE+KV8fD//ujo0ZqZkdj8cbZNyyM6aIlEV7n6Jx5fvluMX9dmJ 4bUQ== MIME-Version: 1.0 X-Received: by 10.66.25.13 with SMTP id y13mr4115361paf.208.1365007810058; Wed, 03 Apr 2013 09:50:10 -0700 (PDT) Sender: php@golemon.com Received: by 10.70.28.65 with HTTP; Wed, 3 Apr 2013 09:50:09 -0700 (PDT) X-Originating-IP: [98.210.180.187] In-Reply-To: References: Date: Wed, 3 Apr 2013 09:50:09 -0700 X-Google-Sender-Auth: xApyzTsoS-sh_71ICh2iaz5i_DM Message-ID: To: Pierre Joye Cc: PHP internals Content-Type: text/plain; charset=ISO-8859-1 X-Gm-Message-State: ALoCoQn+x6fKKdPWkyJPCdCyZ7tMIGtdtdluo8oi6yrPUgehFtOMFIIEFGGUIRHZd5gnOn7zvpUW Subject: Re: [PHP-DEV] [RFC] Simplified Array API for extensions From: pollita@php.net (Sara Golemon) > I would like to kill other APIs in next major as well, time for > cleanup and ease maintenance. Yes, it is a bit more work for > extensions developers but as you plan to do pecl releases as well for > these inlined functions, that should be a good thing in the long run. > I'm not sure how you plan to kill the other APIs since these wrappers depend on them. Also, the engine uses them heavily for... everything. > What do you think about having the same for hashes? Many > implementations do not work with zval but with hash tables as well, > that would be a perfect combination :) > One of the implementation details which this API hides is the fact that zend_hash_find() returns a zval** which is usually just an annoyance to an extension developer, but can be taken advantage of for rewriting array contents (lookup a value and replace in via *ppzval = pzval; ) Not to mention the quick_* variants which CVs and the default class handlers make heavy use of, but are overkill for the average one-off access from an ext function. -Sara