From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Alan Mackenzie Newsgroups: gmane.emacs.bugs Subject: bug#73880: Master: emacs-lisp-mode: Tab completion for a function position fails in a `let' form. Date: Mon, 28 Oct 2024 11:19:09 +0000 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="7088"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 73880@debbugs.gnu.org To: Dmitry Gutov Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Mon Oct 28 12:19:52 2024 Return-path: Envelope-to: geb-bug-gnu-emacs@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 1t5Nmq-0001dE-0h for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 28 Oct 2024 12:19:52 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1t5NmU-00037V-O6; Mon, 28 Oct 2024 07:19:30 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1t5NmS-00037E-56 for bug-gnu-emacs@gnu.org; Mon, 28 Oct 2024 07:19:28 -0400 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1t5NmQ-0004YA-H1 for bug-gnu-emacs@gnu.org; Mon, 28 Oct 2024 07:19:26 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=From:In-Reply-To:MIME-Version:References:Date:To:Subject; bh=HXHwYC+z8GbNgY00oXE+GAgeefiUJ8RiUztllWNE+WI=; b=UZPvQ1PEfbySMwA4YeZNpHmF3u6lMY20WrHhDuMqtNTM1bqdsViVJ9AmaYoJCsz90z8MdFCsvhD5/y9H3jtPmEEzTaSKW4C+AN8e/ksHfkNl4ovbDML9rUfAr3OJqcFf0629NjXINc1Dp1BVUBLJQTbW6opYcyxq6A7tf+6Uv2vV24A26eP+i7sR5363dtWkHEOyXuaV548+4aw8lLMDwQOjkuoiW6osJrO1HqkCq7OD3MGQnieuoRezWJCXmqlsujHlODxn+ZKiUK4JYzG/ruZUe9xJSTGpLYdApb6paHSV23ubuT027IYMKcoj5WPVBbgGkyTwOSRRzM0D45UXmQ==; Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1t5Nn0-0002YZ-8y for bug-gnu-emacs@gnu.org; Mon, 28 Oct 2024 07:20:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Alan Mackenzie Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 28 Oct 2024 11:20:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 73880 X-GNU-PR-Package: emacs Original-Received: via spool by 73880-submit@debbugs.gnu.org id=B73880.17301143969809 (code B ref 73880); Mon, 28 Oct 2024 11:20:02 +0000 Original-Received: (at 73880) by debbugs.gnu.org; 28 Oct 2024 11:19:56 +0000 Original-Received: from localhost ([127.0.0.1]:52727 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1t5Nmt-0002Y8-Ni for submit@debbugs.gnu.org; Mon, 28 Oct 2024 07:19:56 -0400 Original-Received: from mail.muc.de ([193.149.48.3]:53412) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1t5Nmr-0002Xs-Ax for 73880@debbugs.gnu.org; Mon, 28 Oct 2024 07:19:54 -0400 Original-Received: (qmail 68085 invoked by uid 3782); 28 Oct 2024 12:19:10 +0100 Original-Received: from muc.de (p4fe15284.dip0.t-ipconnect.de [79.225.82.132]) (using STARTTLS) by colin.muc.de (tmda-ofmipd) with ESMTP; Mon, 28 Oct 2024 12:19:09 +0100 Original-Received: (qmail 7335 invoked by uid 1000); 28 Oct 2024 11:19:09 -0000 Content-Disposition: inline In-Reply-To: X-Submission-Agent: TMDA/1.3.x (Ph3nix) X-Primary-Address: acm@muc.de X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:294417 Archived-At: Hello, Dmitry. On Sun, Oct 27, 2024 at 03:29:08 +0200, Dmitry Gutov wrote: > On 27/10/2024 01:09, Alan Mackenzie wrote: > >> BTW, I had to move the corresponding piece of code to a separate > >> function to debug it. Too bad edebug doesn't know how to jump into the > >> 'guard' clauses. > > I found the bug in pcase.el causing this. The edebug spec element > > &interpose, which is used in pcase-PAT absolutely requires that the > > function it uses (in this case pcase--edebug-match-pat-args) must call > > PF. (See edebug.el around L1810.) > > What PF (internal function in edebug) does is join up edebug specs with > > what follows. > > pcase--edebug-match-pat-args fails to do this for most cases it deals > > with, including guard. As a result, there is no edebug instrumentation > > generated for the argument of guard. > > I'm going to raise a bug report for this (answering my question in my > > last post). In the meantime, here is a rough first draught of a fix. > > With it, I can debug the guard clauses in elisp-completion-at-point, > > though I seem to be triggering other problems (I get a message about a > > `_' argument being used after all). > Nice! It works, thank you. Thanks for testing it. I've now submitted bug#74052, complete with a patch, for this problem. [ 74052 is easy to remember - it's 66^2 * 17 :-] -- Alan Mackenzie (Nuremberg, Germany).