Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:67620 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 67430 invoked from network); 4 Jun 2013 04:59:29 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 4 Jun 2013 04:59:29 -0000 Authentication-Results: pb1.pair.com header.from=mike.php.net@gmail.com; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=mike.php.net@gmail.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.215.48 as permitted sender) X-PHP-List-Original-Sender: mike.php.net@gmail.com X-Host-Fingerprint: 209.85.215.48 mail-la0-f48.google.com Received: from [209.85.215.48] ([209.85.215.48:52833] helo=mail-la0-f48.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 2E/9B-21406-E247DA15 for ; Tue, 04 Jun 2013 00:59:27 -0400 Received: by mail-la0-f48.google.com with SMTP id fs12so4189259lab.21 for ; Mon, 03 Jun 2013 21:59:23 -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:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type :content-transfer-encoding; bh=T8vVn6ireaUpeePJ1Eapfp8BtQW0bjuqDG1H9Xr+RbU=; b=c2zwG5i/IDR0fDDMS/Pusatt+4IHGJLvtGRl44QQTlXf+7gvnm3ASHrOqPS77jFtf2 gdr8B4Y+mGexZbCpjxlvol2bTviT1i8qjL/Ag+3iwVt3AdJ/RfJaVnS1E7zi0dJAa8Sa SSfcaSqBdjTk8b+U8Eg53jHasVVYo9DGwpFN47l7yH8szaDGvQHxt36Wz2xa20fRuCO9 NwbK+LWKvnYpPR07C6PAsXWt0YGsms3L0b1OYVfETIRwj3/uJdbvcQkA94jgeEVu+jeU Y041JV5HlERyQn97Hr1U+Ir65+DQJfmDTYTwjmI38tGyepgorDdLkLXNAL4aB4hU84os ZdpQ== MIME-Version: 1.0 X-Received: by 10.152.116.7 with SMTP id js7mr12400413lab.7.1370321963090; Mon, 03 Jun 2013 21:59:23 -0700 (PDT) Sender: mike.php.net@gmail.com Received: by 10.114.64.178 with HTTP; Mon, 3 Jun 2013 21:59:22 -0700 (PDT) In-Reply-To: <5466EBBB-C74D-4498-9DBD-338F460694A5@schlueters.de> References: <5466EBBB-C74D-4498-9DBD-338F460694A5@schlueters.de> Date: Tue, 4 Jun 2013 06:59:22 +0200 X-Google-Sender-Auth: 4tVPH33vv3K030PyVHbFcj2ds_g Message-ID: To: =?UTF-8?Q?Johannes_Schl=C3=BCter?= Cc: Pierre Joye , Anthony Ferrara , "internals@lists.php.net" Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Subject: Re: [PHP-DEV] 5.NEXT Integer and String type modifications From: mike@php.net (Michael Wallner) On 2 June 2013 11:11, Johannes Schl=C3=BCter wrote= : > > > On Jun 2, 2013, at 8:34, Pierre Joye wrote: > >>> Obviously there's a pretty significant ABI break here. I propose a "twe= ak" >>> of the Z_* macros to "fix" that. Basically, Z_STRLEN() will cast the re= sult >>> to an int. This is the same behavior as today, and will mean that exist= ing >>> extensions continue to function exactly as today. But new extensions (a= nd >>> elsewhere in core) can use a new macro Z_STRSIZE() which will return th= e >>> native size_t. >> >> A new macro will be a good solution, but I would name it what it >> actually is, Z_SIZE_T. > > That's not what it is. It is the length of the string aka. var.value.str.= length as such it should indicate its relation to a string. So something li= ke Z_STRSIZE is correct (and the name is nice thinking about Unicode strin= gs where length (characters) !=3D size (bytes)) +1 for the idea +1 for Z_STRSIZE +1 for volunteering, as far as time permits! -- Regards, Mike