From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Nicolas Petton Newsgroups: gmane.emacs.devel Subject: Re: seq-group-by returns groups in wrong order? Date: Wed, 11 Feb 2015 14:38:29 +0100 Message-ID: <87mw4kh8kq.fsf@petton.fr> References: <8761bdi4ln.fsf@mailbox.org> <87egpzi8bf.fsf@petton.fr> <87twytbj9j.fsf@mailbox.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1423661927 30031 80.91.229.3 (11 Feb 2015 13:38:47 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 11 Feb 2015 13:38:47 +0000 (UTC) Cc: emacs-devel@gnu.org To: Alexander Baier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Wed Feb 11 14:38:41 2015 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1YLXV2-0003iB-3C for ged-emacs-devel@m.gmane.org; Wed, 11 Feb 2015 14:38:40 +0100 Original-Received: from localhost ([::1]:45081 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YLXV1-0004JM-Go for ged-emacs-devel@m.gmane.org; Wed, 11 Feb 2015 08:38:39 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:50286) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YLXUx-0004J6-VI for emacs-devel@gnu.org; Wed, 11 Feb 2015 08:38:36 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YLXUt-0002S6-SN for emacs-devel@gnu.org; Wed, 11 Feb 2015 08:38:35 -0500 Original-Received: from out4-smtp.messagingengine.com ([66.111.4.28]:34250) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YLXUt-0002S2-ON for emacs-devel@gnu.org; Wed, 11 Feb 2015 08:38:31 -0500 Original-Received: from compute6.internal (compute6.nyi.internal [10.202.2.46]) by mailout.nyi.internal (Postfix) with ESMTP id 6ACC8207E7 for ; Wed, 11 Feb 2015 08:38:31 -0500 (EST) Original-Received: from frontend1 ([10.202.2.160]) by compute6.internal (MEProxy); Wed, 11 Feb 2015 08:38:31 -0500 DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d= messagingengine.com; h=x-sasl-enc:references:from:to:cc:subject :in-reply-to:date:message-id:mime-version:content-type; s= smtpout; bh=FXbDaPyh6Of975AN7nAQ7cP3LaE=; b=Qw2ynhPscV9PKP4kHvfZ wFb/6Aw8tCzCsbiaMWuyu63TezNWGA5mKCzbnJUBGUp54uf3bcO1jyaDCA1UNRwy sibgTZgLHqDM7xM6dy4jZgTxNXZdTTkO1th981Otf5mPGi5C5TAyA8h7kK02bRcX uJIarbYLg6fJEuUOeRyZJh4= X-Sasl-enc: MrCOO6vfjGF8iJh0DdK2d70KF2EEMRm2Ze6Qd6kXfTW+ 1423661911 Original-Received: from blueberry (unknown [81.57.68.248]) by mail.messagingengine.com (Postfix) with ESMTPA id F00ABC0028D; Wed, 11 Feb 2015 08:38:30 -0500 (EST) User-agent: mu4e 0.9.9.6pre3; emacs 24.4.1 In-reply-to: <87twytbj9j.fsf@mailbox.org> X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 66.111.4.28 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:182881 Archived-At: Alexander Baier writes: > On 2015-02-09 13:21 Nicolas Petton wrote: >> Alexander Baier writes: >> >>> Hello, >>> >>> The groups returned by seq-group-by are reversed, is this intended >>> behaviour? >>> >>> (seq-group-by #'oddp [1 2 3 4 5]) >>> ;; => ((t 5 3 1) (nil 4 2)) >>> >>> I was expecting ((t 1 3 5) (nil 2 4)) to be returned. This is seq.el >>> from elpa, version 1.1. >> >> I updated it both in Emacs master and GNU ELPA, and bumped the version >> number to 1.1.1. > > I just tested the new version and found it only works with lists, but > not with vectors or strings. This seems to be because (seq-)reverse only > operates on lists. Yes, I'm adding a backward-compatible version of seq-reverse for Emacs 24. Cheers, Nico -- Nicolas Petton http://nicolas-petton.fr