From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Michael Heerdegen Newsgroups: gmane.emacs.devel Subject: Re: Enhance seq-min and seq-max Date: Tue, 25 Jun 2019 23:22:02 +0200 Message-ID: <87sgrxmkcl.fsf@web.de> References: <87o932d0qh.fsf@petton.fr> <87blz1ozp5.fsf@web.de> <87tvcsab8e.fsf@petton.fr> <87a7ejelul.fsf_-_@web.de> <87wohm76ox.fsf@web.de> <87imt59tpm.fsf@petton.fr> <87sgs9glqb.fsf@web.de> <87blywac2x.fsf@petton.fr> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="259135"; mail-complaints-to="usenet@blaine.gmane.org" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) Cc: Emacs Devel To: Nicolas Petton Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Jun 25 23:38:45 2019 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([209.51.188.17]) by blaine.gmane.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1hft9J-0015Ii-Ci for ged-emacs-devel@m.gmane.org; Tue, 25 Jun 2019 23:38:45 +0200 Original-Received: from localhost ([::1]:35436 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hft9I-0001kh-9y for ged-emacs-devel@m.gmane.org; Tue, 25 Jun 2019 17:38:44 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:43323) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hfstW-0001LT-7T for emacs-devel@gnu.org; Tue, 25 Jun 2019 17:22:27 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hfstR-000805-9J for emacs-devel@gnu.org; Tue, 25 Jun 2019 17:22:23 -0400 Original-Received: from mout.web.de ([212.227.15.14]:36551) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hfstQ-0007mz-1X for emacs-devel@gnu.org; Tue, 25 Jun 2019 17:22:20 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=web.de; s=dbaedf251592; t=1561497723; bh=PkkuDCjxz7yHMljLcZSLoG8qfh5/MIiJum3MgxIogFE=; h=X-UI-Sender-Class:From:To:Cc:Subject:References:Date:In-Reply-To; b=d1Z5YoNGjuikc2PCQsqrfQ6A1FPlbq8eOw1k0Ih58TGRN4TVsrwLHm67/08SpITQs TmJVNauHYIx88ZVqzI0z39PeNOuYxbiVM/xtHf+LLraAiz92mxONUMKr7t0b+vGVhI 8cZNPlfj2y8J0kDRnxMO8b35fCHcF8FSgf1CpZog= X-UI-Sender-Class: c548c8c5-30a9-4db5-a2e7-cb6cb037b8f9 Original-Received: from drachen.dragon ([94.218.184.73]) by smtp.web.de (mrweb001 [213.165.67.108]) with ESMTPSA (Nemesis) id 0MKaHP-1hgiVA2GJz-001vzz; Tue, 25 Jun 2019 23:22:03 +0200 In-Reply-To: <87blywac2x.fsf@petton.fr> (Nicolas Petton's message of "Mon, 17 Jun 2019 09:46:30 +0200") X-Provags-ID: V03:K1:OhRGd68MePqgU2CC40B4q3pBNaaVwZAUeKoMpAg/jKz3BaXgqyn DsAfHf0+DiMnDKvcxfV+BL0PaGXr7BpGwy3JbAO9kBrrdDrFP+Fs023ulVrUXFW8fp+yJNb 970sKnizyP9c3qbZ2eIQaXZw/zKZnRU+fim/Zi/4uTokQIH4kRCOOcX+U+dy5N2pp8xozVd R4Lm7jUKDLOgsJfKKCP7w== X-UI-Out-Filterresults: notjunk:1;V03:K0:qB5/kW1nlyE=:CK5H4FafMN+JT7DRy+5R8k zMk2BBnS6M8pfQP+/xdy2Q9XaTDVOnpGxgbQrVlaM8GFNa+man9vwBtXSdNZSITl8cp1BkdTW Vg9rYcP4mpYWWhDkuwoe1OjZOquifyhERmKW9oozmUrUwyIZgdWobg2P3CcWVCyeC90u936DF 4nrEzE7NuKcLateRmEtzXECLNDrAyC9dDBB1L8UFVyuxwzS8gltFa7lkkGROSXQ898xSIgTtO eUvuE7DRjubNFYEOKil7HYSmE+m9lordkkveV7YRxzmRGaLbPGc0mKZy4sWh2Wfa7kFpzeY4g bi2Ln0+CZcPF7WNV15blM3XuvFUoua7SjqHG0Q2F/IYmf5Q+e3Yt3IZwl+cPxHQLfXF+GujxP 30oiasY2bzDNo+krXQbi1sdP0IOihW4YY9woxoq+j+4iav97sOFs3jDiMNLaH92aqm0pjwqrz u9i5D1ER4AV5J0pHC0X/IhnTU4WMOK5fhDzWJf8vXLB5oQbsRiocj09zxglSz81TTB6ul3En3 aAWEghRrmxdtQsIPI4RSvbQh3E+iyyKoyuCODr8PgluuvIqZyQqjsOngF/UoEkt6bbKVamZbD phuGCWZ9kk16oF6bQHoY279iZg+GtPKveuWET6/rooQonnGF4C1E/WnmkdWcryEOhE6djgYIS QJuJQUVX8VYWDBFv3qtY/reEgl692Dg700v7FQpv2lpz3T+39xmMIpCPnMrVspoBQMjOidxqw QjggO+gtXAFbH9esc+6cJuJ+GLeWLNLS2RcW2EQgRrPZm/B+7nj4k1kqdgYI1pCaJAKNN4Pb X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 212.227.15.14 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 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" Xref: news.gmane.org gmane.emacs.devel:238147 Archived-At: Nicolas Petton writes: > > I wonder if I should rather give one general definition in the > > function body and handle the four cases (KEY/PREDICATE given/not > > given) in a compiler macro. Then in compiled code there would be no > > runtime tests and it would be optimized for the respective case. > > As you wish, but depending on what exactly you have in mind, it might be > better not to do it, so that `seq-min' and `seq-max' can still easily be > overwritten for custom seq types. I guess what I planned is nonsense: If the method is chosen at run-time, it doesn't make sense to optimize the method for lists with a compiler macro. It's not a critical issue anyway, so I'll just go with what I have so far (and finish the documentation stuff). Michael.