Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:80696 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 75071 invoked from network); 17 Jan 2015 14:21:09 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 17 Jan 2015 14:21:09 -0000 Authentication-Results: pb1.pair.com header.from=pierre.php@gmail.com; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=pierre.php@gmail.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.216.173 as permitted sender) X-PHP-List-Original-Sender: pierre.php@gmail.com X-Host-Fingerprint: 209.85.216.173 mail-qc0-f173.google.com Received: from [209.85.216.173] ([209.85.216.173:35535] helo=mail-qc0-f173.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id A3/00-09166-4DF6AB45 for ; Sat, 17 Jan 2015 09:21:09 -0500 Received: by mail-qc0-f173.google.com with SMTP id m20so9933473qcx.4 for ; Sat, 17 Jan 2015 06:21:05 -0800 (PST) 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=b2CmBZuJnKVBDcGhMh8jp0S7ot3yTEGBqtEZH2tZqio=; b=TSQLjyWHfA0vsnU8W9YmtnA5DS5Jsvt/NdGAWX+A3IK96hE5uVVFpaByQcAwGamKCA 6epYRSmZrb98jJhvYCcuAC2WbghlcSyyjb1C009v7ITS6omhqO4gHBwVgNPrB6U/A/t+ C9p/1sr9KZ05IxFJ4QbnTvoGdZ9Jv3KEkvGVhjVsodsKc5ZPe8Zh6iNk/BwmYtSJFJqY diPTMM+fYZFGeLRXFn3pGQHkNFBytZkcueyj84nBNYzaEezNtd53yxtu0wVAAJ0ihwhE FCITaYpk8icds+Fes1NUG/NNGqq5/oE17z0abYzaH6H1M3E9QWHemj0sH3Reb44xFs+U IwvQ== MIME-Version: 1.0 X-Received: by 10.224.54.2 with SMTP id o2mr34102605qag.63.1421504465833; Sat, 17 Jan 2015 06:21:05 -0800 (PST) Received: by 10.140.22.106 with HTTP; Sat, 17 Jan 2015 06:21:05 -0800 (PST) Received: by 10.140.22.106 with HTTP; Sat, 17 Jan 2015 06:21:05 -0800 (PST) In-Reply-To: <2B8F3D41-F7D3-4754-88B0-E740FDA6AA04@ajf.me> References: <53CEC194.5090307@marc-bennewitz.de> <2DD279B4-E872-4FDA-9FDC-12770D4BF052@ajf.me> <2B8F3D41-F7D3-4754-88B0-E740FDA6AA04@ajf.me> Date: Sat, 17 Jan 2015 21:21:05 +0700 Message-ID: To: Andrea Faulds Cc: Marc Bennewitz , PHP internals Content-Type: multipart/alternative; boundary=001a1132f080bb9536050cd9cc80 Subject: Re: [PHP-DEV] unsinged integer From: pierre.php@gmail.com (Pierre Joye) --001a1132f080bb9536050cd9cc80 Content-Type: text/plain; charset=UTF-8 On Jan 17, 2015 7:22 PM, "Andrea Faulds" wrote: > > Hey Pierre, > > > On 17 Jan 2015, at 05:56, Pierre Joye wrote: > > > > It looks to me like yet another can of worms (how do you deal with > > conversions, mixed operations, etc. it adds a lot of special cases) > > with little benefits. > > The conversions are trivial and there are no operations to implement. The only "support" added would be one more zend_parse_parameters option. > > > 32bit environments are dying species. There are > > ways to support LFS without that as well (while I doubt the effort is > > worth it). So if I'd to choose whether PHP should support unsigned > > integer, my gut feeling right now is no, it should not. > > This wouldn't be unsigned integer support though, it'd just be a conversion mechanism. > > Also, it has some use beyond 32-but systems. On 64-bit, it would be useful for, e.g. pack() and unpack(). I can indeed imagine some use cases for "optimized" math/ops in userland using unsigned integer (legacy or bigint). However I am not really convinced we should use them. Or if we do I would also like to have more (like c# f.e.) but it would b very tricky to use in php, due to its nature. > Thanks. > > -- > Andrea Faulds > http://ajf.me/ --001a1132f080bb9536050cd9cc80--