Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 10 Dec 1999 06:30:02 -0800 (PST)
From:      "Andrey A. Chernov" <ache@freebsd.org>
To:        freebsd-bugs@FreeBSD.org
Subject:   Re: bin/15370: bug in sort
Message-ID:  <199912101430.GAA53631@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help
The following reply was made to PR bin/15370; it has been noted by GNATS.

From: "Andrey A. Chernov" <ache@freebsd.org>
To: Nikita Shamgunov <nsh@dream.mplik.ru>
Cc: FreeBSD-gnats-submit@freebsd.org
Subject: Re: bin/15370: bug in sort
Date: Fri, 10 Dec 1999 06:20:40 -0800

 On Thu, Dec 09, 1999 at 02:50:52PM +0500, Nikita Shamgunov wrote:
 > #
 > # Неверно сортирует
 > my @array1 = sort {lc($a) cmp lc($b)} @array;
 
 It looks like some problem with lc+cmp combination.
 It works when result of lc assigned to variable first, i.e.
 
 sub comp {
 $aa = lc($a);
 $bb = lc($b);
 return $aa cmp $bb;
 }
 
 -- 
 Andrey A. Chernov
 http://nagual.pp.ru/~ache/
 MTH/SH/HE S-- W-- N+ PEC>+ D A a++ C G>+ QH+(++) 666+>++ Y
 


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-bugs" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199912101430.GAA53631>