Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:85740 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 35524 invoked from network); 7 Apr 2015 14:34:04 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 7 Apr 2015 14:34:04 -0000 Authentication-Results: pb1.pair.com smtp.mail=dmitry@zend.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=dmitry@zend.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain zend.com designates 209.85.216.50 as permitted sender) X-PHP-List-Original-Sender: dmitry@zend.com X-Host-Fingerprint: 209.85.216.50 mail-vn0-f50.google.com Received: from [209.85.216.50] ([209.85.216.50:38940] helo=mail-vn0-f50.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id F9/30-33115-8DAE3255 for ; Tue, 07 Apr 2015 10:34:01 -0400 Received: by vnbg62 with SMTP id g62so9188439vnb.6 for ; Tue, 07 Apr 2015 07:33:57 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=8v7FHcmcp7/HiNWyfPY4zaHOqkS+T+ySfOAbVORbj7E=; b=h6rU9niUNooJNoVdtcdp73bN/8YpuxpGPBDpd+KYetb13ELFOTyt57eVgqWKFTxuaw hErISi/sJVo7PH9vzUOhetmna4Gx/Tljh2DXHGZWEiNMuQNSG9y3Mj4tIdeZg6iI/C8l pNG/LUVxI/R4Sl8TZ8xWqgLCvES09lTarghVxySeJNLjgQh3RYYB3JjgD5Ikukr1R6wc n9TiwnL0c/TLL7sOu2zKNiDJbbgftyK2NjY6uabFpxMxeGWbxMxiyY4D25PkCIJWM35a 9Up09fhKDVAMM2tUgqXCesJqJpjIzjiM6OIgopRRCxD1gaVE7b2lr4sT7Re7Gh5sysls YKwg== X-Gm-Message-State: ALoCoQmOYFi1AK//rFDisF6erZLLR6KMg9zHgQkT+dFxSxmZhpqycwWsa2mokpi57Fa/cmaysFyr5Spq6BDssqW5KN5U/vFtTBF9l2HTx2w/Ued+A4OLNEPfBxEU4rgK4o7SlwnlYgMNek/om3WWI3g75+c6izBgAg== MIME-Version: 1.0 X-Received: by 10.52.35.132 with SMTP id h4mr10959789vdj.65.1428417237746; Tue, 07 Apr 2015 07:33:57 -0700 (PDT) Received: by 10.52.248.36 with HTTP; Tue, 7 Apr 2015 07:33:57 -0700 (PDT) In-Reply-To: <5523DF0E.6000500@hristov.com> References: <5523DF0E.6000500@hristov.com> Date: Tue, 7 Apr 2015 17:33:57 +0300 Message-ID: To: Andrey Hristov Cc: PHP internals , Dmitry Stogov Content-Type: multipart/alternative; boundary=20cf307cfd0e0c1c4f0513234e33 Subject: Re: [PATCH] Tick functions (on C level) with state From: dmitry@zend.com (Dmitry Stogov) --20cf307cfd0e0c1c4f0513234e33 Content-Type: text/plain; charset=UTF-8 Hi Andrey, I didn't get why do you need this extension and how it's going to be used. Thanks. Dmitry. On Tue, Apr 7, 2015 at 4:43 PM, Andrey Hristov wrote: > Hi, > I would like to hear comments about a small change to the low-level tick > functionality (main/php_ticks.c) to add state to when calling a C tick > function > The patch is alive at : http://pastebin.com/0zhVNxaY > > Currently a C tick function gets as a parameter just the number of ticks, > and can't preserve state between calls. On PHP level one can use closures > to mitigate this, but in the C world we don't have this luxury. > > Any comments are very welcome. If possible to get in PHP7. > > > Cheers, > Andrey > --20cf307cfd0e0c1c4f0513234e33--