Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:61648 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 74256 invoked from network); 23 Jul 2012 15:30:14 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 23 Jul 2012 15:30:14 -0000 Authentication-Results: pb1.pair.com smtp.mail=keisial@gmail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=keisial@gmail.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.214.42 as permitted sender) X-PHP-List-Original-Sender: keisial@gmail.com X-Host-Fingerprint: 209.85.214.42 mail-bk0-f42.google.com Received: from [209.85.214.42] ([209.85.214.42:54545] helo=mail-bk0-f42.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 22/E1-63091-50E6D005 for ; Mon, 23 Jul 2012 11:30:14 -0400 Received: by bkcjm19 with SMTP id jm19so5054235bkc.29 for ; Mon, 23 Jul 2012 08:30:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:content-type:content-transfer-encoding; bh=JwmsfDcjM3RYwnx4SC1wdRjQU8GnhhvTWt4f8sj2/F8=; b=dRmdzLL+5ol+BjDyFl6JieLEvH2y+Qs4H2/UOWbhK/ehUhUZPum/Eru13E1/Xl5IVs oIbj/uyAIhy/0Tc+Eo6odO3FiLFeRA11shATFgrowE9njhuu3kg+rGTYdx55OzycQlmj HLCVAKMwDi6sk3+D88iEq0C+NAZGuuyEpM9yk0CscwewMcDLpYp+5z5geZvDn+YrOzE1 DYF/wff3CIU+3DH5Y1xfIJzxfyoehtDFlBN545EqSCH26708IbYQxZ7RU65t7P8CAxwZ BRdPhbXMHg/WJtg1qkPjuc0WBPQmx6nfq4vxuioosXcsbSJt+IP7ozD+gAvaCQZxgR2v Dmjg== Received: by 10.204.10.70 with SMTP id o6mr8041332bko.31.1343057410477; Mon, 23 Jul 2012 08:30:10 -0700 (PDT) Received: from [192.168.1.26] (155.Red-83-55-230.dynamicIP.rima-tde.net. [83.55.230.155]) by mx.google.com with ESMTPS id o4sm7994970bkv.15.2012.07.23.08.30.08 (version=SSLv3 cipher=OTHER); Mon, 23 Jul 2012 08:30:09 -0700 (PDT) Message-ID: <500D6DDF.3070308@gmail.com> Date: Mon, 23 Jul 2012 17:29:35 +0200 User-Agent: Thunderbird MIME-Version: 1.0 To: Kris Craig CC: Andrew Faulds , Tjerk Meesters , "internals@lists.php.net" , Rasmus Schultz References: <5009C8AA.10603@sugarcrm.com> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Subject: Re: [PHP-DEV] common issue with version_compare() From: keisial@gmail.com (=?ISO-8859-1?Q?=C1ngel_Gonz=E1lez?=) On 22/07/12 04:08, Kris Craig wrote: > On Sat, Jul 21, 2012 at 3:09 AM, Andrew Faulds wrote: > >> If you think 1.1 =/= 1.01 you're sure using some weird version numbers. >> Only 1.0.1 would be smaller. >> >> Has anyone seen these weird version ordering schemes in practise? On any >> major projects of note? >> >> > *raises his hand* > > 1.01 and 1.0.1 are essentially the same thing. No, it is not. > If a versioning model doesn't utilize the second dot (many don't), then 1.01 would be the same as > 1.0.1 in a project that does use it. It's the first time I hear about a project writing 1.0.1 as 1.01 > The Gitflow model reserves that last digit for hotfixes. However, many > developers (including myself) drop the second dot as it's pretty much > superfluous. Maybe that's an American thing, I dunno. But having 1.1 == > 1.01 would cause this function to be completely and utterly *worthless *for > many developers like myself. It doesn't matter that you bump the minor or revision number, it's up to each project what should increase on a change of X severity. It would still work flawlesslly as far as you do it consistently. If you release 1.0.1, 1.02, 1.0.3 and expect it to order that way, it will fail. And I guess that so would many developers too.