From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Gemini Lasswell Newsgroups: gmane.emacs.bugs Subject: bug#28747: 26.0.60; Usage of "&rest body" in Edebug specs Date: Sun, 08 Oct 2017 08:02:56 -0700 Message-ID: <87o9phznq7.fsf@runbox.com> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1507475052 20445 195.159.176.226 (8 Oct 2017 15:04:12 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sun, 8 Oct 2017 15:04:12 +0000 (UTC) To: 28747@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun Oct 08 17:04:07 2017 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1e1D7e-0004WY-Ue for geb-bug-gnu-emacs@m.gmane.org; Sun, 08 Oct 2017 17:04:07 +0200 Original-Received: from localhost ([::1]:54001 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1e1D7l-0001IK-0J for geb-bug-gnu-emacs@m.gmane.org; Sun, 08 Oct 2017 11:04:13 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:49855) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1e1D7e-0001I1-C1 for bug-gnu-emacs@gnu.org; Sun, 08 Oct 2017 11:04:07 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1e1D7a-00089k-Aw for bug-gnu-emacs@gnu.org; Sun, 08 Oct 2017 11:04:06 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:47823) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1e1D7a-00089e-75 for bug-gnu-emacs@gnu.org; Sun, 08 Oct 2017 11:04:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1e1D7Z-0004G3-QH for bug-gnu-emacs@gnu.org; Sun, 08 Oct 2017 11:04:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Gemini Lasswell Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 08 Oct 2017 15:04:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 28747 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.150747503316349 (code B ref -1); Sun, 08 Oct 2017 15:04:01 +0000 Original-Received: (at submit) by debbugs.gnu.org; 8 Oct 2017 15:03:53 +0000 Original-Received: from localhost ([127.0.0.1]:56504 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1e1D7R-0004Fd-9u for submit@debbugs.gnu.org; Sun, 08 Oct 2017 11:03:53 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:58770) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1e1D7P-0004FQ-NQ for submit@debbugs.gnu.org; Sun, 08 Oct 2017 11:03:52 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1e1D7J-00084L-Pl for submit@debbugs.gnu.org; Sun, 08 Oct 2017 11:03:46 -0400 Original-Received: from lists.gnu.org ([2001:4830:134:3::11]:48133) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1e1D7J-00084H-MO for submit@debbugs.gnu.org; Sun, 08 Oct 2017 11:03:45 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:49739) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1e1D7I-0001GU-HJ for bug-gnu-emacs@gnu.org; Sun, 08 Oct 2017 11:03:45 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1e1D7E-00082V-Fr for bug-gnu-emacs@gnu.org; Sun, 08 Oct 2017 11:03:44 -0400 Original-Received: from aibo.runbox.com ([91.220.196.211]:37552) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1e1D7E-000808-4Y for bug-gnu-emacs@gnu.org; Sun, 08 Oct 2017 11:03:40 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=runbox.com; s=rbselector1; h=Content-Type:MIME-Version:Message-ID:Date:Subject:To:From; bh=X8ib8o2lY/0fsGB1uRrfE6S4puyIqvYh+O2czu9TsfY=; b=KQ5u0CXUqaQV/E71DXa5KNOjF XMux+BxKkk+xBDckAFRjVvyvBoaLBRJNsmzfvaGYSS8UIMYQqFO8OHF5qNfoIjdJbPb4m/RGSpq4C SXGZQPk2q//DiDfN2HXM7BZKh2WrVu6XFHfrY+Zrrm2srkiuELVahDx6Y1vRjTrRwUUdIczrGW7sU jiSMx6iWs3pkRgpYDMveS5/pWzEOY9rmeWAMLhnRejhGWOsl1MHOraUK/3eGzDDnGG+ODFJBpD5CH +TViZLB6MD44T0sww5e7GRui5QV6E4Vv25Mex9QlMSszAWhGudR/ybRJOF5f3Lof6BlQMy349raor yhAt+K+qQ==; Original-Received: from [10.9.9.210] (helo=mailfront10.runbox.com) by mailtransmit03.runbox with esmtp (Exim 4.86_2) (envelope-from ) id 1e1D78-0002Jz-Ea for bug-gnu-emacs@gnu.org; Sun, 08 Oct 2017 17:03:34 +0200 Original-Received: from c-24-22-244-161.hsd1.wa.comcast.net ([24.22.244.161] helo=chinook) by mailfront10.runbox.com with esmtpsa (uid:179284 ) (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) id 1e1D6Y-00079d-Ux for bug-gnu-emacs@gnu.org; Sun, 08 Oct 2017 17:02:59 +0200 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 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.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:138077 Archived-At: The symbol &rest in an Edebug spec has a different meaning than it has in an argument list. In particular, "&rest body" in an Edebug spec is erroneous usage because it is asking Edebug to match something that can match nothing (body) as many times as it can, which makes an infinite loop. To repro, navigate to the definition of crm-completion-help in lisp/emacs-lisp/crm.el and: M-x eval-buffer RET C-u C-M-x Result: Too deep - perhaps infinite loop in spec? Here are the macros I've found that have this incorrect usage of &rest in their Edebug specs: crm--completion-command easy-mmode-define-navigation inline--letlisteval inline--leteval ses--letref Edebug specs have been using &rest for a really long time and it mostly gets used correctly. But &repeat would be better, since it actually describes the functionality and doesn't have a completely different and more common usage in argument lists. Here's a little example of what an Edebug spec would look like with &repeat in place of &rest: (defmacro msgmac (&rest args) (declare (debug ("start" [&repeat "middle"] "end"))) `(message "%s" ',args)) (defun use-msgmac () (msgmac start end) (msgmac start middle end) (msgmac start middle middle end)) Does anyone have thoughts on the idea of adding &repeat as a synonym for &rest in Edebug specs, with the goal of moving &rest towards obsolescence eventually?