Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:11584 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 6587 invoked by uid 1010); 27 Jul 2004 19:33:37 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 6374 invoked from network); 27 Jul 2004 19:33:35 -0000 Received: from unknown (HELO coggeshall.org) (69.56.217.178) by pb1.pair.com with SMTP; 27 Jul 2004 19:33:35 -0000 Received: from coggeshall.org (localhost.localdomain [127.0.0.1]) by coggeshall.org (8.12.8/8.12.8) with ESMTP id i6RJmSED014841 for ; Tue, 27 Jul 2004 14:48:28 -0500 Received: from localhost (coogle@localhost) by coggeshall.org (8.12.8/8.12.8/Submit) with ESMTP id i6RJmS7a014837 for ; Tue, 27 Jul 2004 14:48:28 -0500 Date: Tue, 27 Jul 2004 14:48:28 -0500 (CDT) Reply-To: John Coggeshall To: internals@lists.php.net Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Subject: Sorting Bug / Wrong behavior? From: coogle@coggeshall.org (John Coggeshall) Consider the following: 0, 'b'=>1, 'c'=>2); sort($a); print_r($a); ?> This produces a bogus output: Array ( [0] => a [1] => b [2] => 0 [3] => c [4] => 1 [5] => 2 ) Notice how 0 and c are switched incorrectly. Attached is a patch to zend_operators.c that fixes it.