From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Lars Ingebrigtsen Newsgroups: gmane.emacs.devel Subject: Re: Smarter M-x that filters on major-mode Date: Thu, 11 Feb 2021 12:00:20 +0100 Message-ID: <87v9aydg3f.fsf@gnus.org> References: <8ed9b43502ae1480e06b@heytings.org> <83r1lohqoc.fsf@gnu.org> <87wnvfenry.fsf@gnus.org> <87blcrdlqf.fsf@gnus.org> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="27918"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) Cc: emacs-devel@gnu.org To: Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Thu Feb 11 12:02:25 2021 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lA9js-00079j-G6 for ged-emacs-devel@m.gmane-mx.org; Thu, 11 Feb 2021 12:02:24 +0100 Original-Received: from localhost ([::1]:60800 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lA9jr-0006S5-HC for ged-emacs-devel@m.gmane-mx.org; Thu, 11 Feb 2021 06:02:23 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:37052) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lA9i5-0005nO-T2 for emacs-devel@gnu.org; Thu, 11 Feb 2021 06:00:33 -0500 Original-Received: from quimby.gnus.org ([2a01:4f9:2b:f0f::2]:43400) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lA9i3-0000Q9-HW for emacs-devel@gnu.org; Thu, 11 Feb 2021 06:00:33 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date: References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=Z2ls1tMpddgVO+JRWEhWJeaPCyPYnH9TVJa9AnoLDDM=; b=t8LZoCXobsR88uul1FZGFIAjrI /qp891Xs1j0C4C43CI0WMRzALaYDt1olC2pJQxgwTBuADPEBS4ej1iFKUcWTZGW121y9iAuMtePKw ZfqO7pkysqya93Kj4rdgj7wdJ4s1A9xCmmY6+boc3iOmIox1LBEyBe7O/GZtgL3fn9Wc=; Original-Received: from cm-84.212.202.86.getinternet.no ([84.212.202.86] helo=xo) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lA9ht-0002Ac-Ro; Thu, 11 Feb 2021 12:00:27 +0100 Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwAgMAAAAqbBEUAAAABGdBTUEAALGPC/xhBQAAACBj SFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAADFBMVEVCMDimTFitl4L/ ///CA72vAAAAAWJLR0QDEQxM8gAAAAd0SU1FB+UCCwo3DLO6nTkAAAG5SURBVCjPPZBBa9tAEIWf hFfYe3KCFVIdA4XUv2JS7B5yWhmNIbq11CHVr9gcDMUny0TB9kkpspD2V3bWLh1YmI95896wwNIW J3euAripI5u30rp3IHIWm01b5R7CGj02p+QCznbq8bReuhzQAqtvpYADph0+mAbm6OHRYs1kkHvr O4u4zeih6GUidfNeZYFEw6LG8+Lpc+QqJ60NDhTzRu5BJ0mHSca5BxcMo1+x4aUch87V0csPksmq gmuKUfN9xsueGXCdbj6yUdWThEzrpD5xxYVPVDYp32Ju3VAgRFKWKTs38isCTR8UThOOWyRNH504 1w4Di6QruGhi/QeOwmSvuLll3cJZmxzG6tlU+g7XX7W2yrS7Uk9lMtQ2aOojhaG3Fs+fixb6WlK1 VmZldoXVIAxVYFa7Q2FD+YN7BCbd7fGvlDHlfmX/w+73kC69wPbcyddPAg8vZxnPAhK4R4wApAKk F1kNmgALrxnLiwXSV9/44RwgS2yuMBAHKHpAlY2h8i1jYEpak8BMzZGZV6q2sYDsUJZi9pZCPRGL +wIwIqOrTCBi+mQEYpENIsJEduYkoEKmL/QX+SqirXh/okEAAAAldEVYdGRhdGU6Y3JlYXRlADIw MjEtMDItMTFUMTA6NTU6MTErMDA6MDAmYtNLAAAAJXRFWHRkYXRlOm1vZGlmeQAyMDIxLTAyLTEx VDEwOjU1OjExKzAwOjAwVz9r9wAAAABJRU5ErkJggg== X-Now-Playing: Little Annie's _Soul Possession_: "Turkey Girl" In-Reply-To: <87blcrdlqf.fsf@gnus.org> (Lars Ingebrigtsen's message of "Thu, 11 Feb 2021 09:58:32 +0100") Received-SPF: pass client-ip=2a01:4f9:2b:f0f::2; envelope-from=larsi@gnus.org; helo=quimby.gnus.org X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action 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-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:264363 Archived-At: I started tinkering with this -- I've now got (defun foo (arg) (command foo-mode "p")) working in the sense that it doesn't do anything. :-) That is, that's now 100% equivalent to `interactive'. But I'm wondering where to stash the mode. Well, for uncompiled functions, that's kinda obvious, but byte-compiled functions stash this in the sixth slot in the bytecode object. Would extending the object (and stash it in the seventh slot) make sense? It'd make the bytecode massively incompatible with previous versions, but it generally is pretty incompatible. -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no