From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Juanma Barranquero Newsgroups: gmane.emacs.devel Subject: Re: eldoc hint for dolist is confusing Date: Sat, 24 Jan 2009 02:36:21 +0100 Message-ID: References: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1232761000 402 80.91.229.12 (24 Jan 2009 01:36:40 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 24 Jan 2009 01:36:40 +0000 (UTC) Cc: Liang Wang , emacs-devel@gnu.org To: Glenn Morris Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sat Jan 24 02:37:53 2009 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1LQXT6-0006s2-Ms for ged-emacs-devel@m.gmane.org; Sat, 24 Jan 2009 02:37:52 +0100 Original-Received: from localhost ([127.0.0.1]:51295 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LQXRo-00030F-Bx for ged-emacs-devel@m.gmane.org; Fri, 23 Jan 2009 20:36:32 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1LQXRi-0002x4-Bd for emacs-devel@gnu.org; Fri, 23 Jan 2009 20:36:26 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1LQXRh-0002vX-GA for emacs-devel@gnu.org; Fri, 23 Jan 2009 20:36:26 -0500 Original-Received: from [199.232.76.173] (port=59356 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LQXRh-0002vP-D3 for emacs-devel@gnu.org; Fri, 23 Jan 2009 20:36:25 -0500 Original-Received: from mail-ew0-f20.google.com ([209.85.219.20]:47675) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1LQXRg-00080u-0j; Fri, 23 Jan 2009 20:36:24 -0500 Original-Received: by ewy13 with SMTP id 13so4475036ewy.18 for ; Fri, 23 Jan 2009 17:36:21 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:message-id:subject:from:to:cc:content-type :content-transfer-encoding; bh=xBw3kQUka1kH2afL0HD/58XFgIdEbdvHz8MghXw+abk=; b=o4T5L6H3ssmwoYYPI9X25JT4VUM7irt4vIk+2hoxoaN8a0VCd3vrvmuD4jYzBUKyYI B4icVcAmNBV8FCP7WOO1/QnKYWMQk5eH73jAbYnPnZ0BcZ+YaG2rYCVi2OFtzFTeh3EY X8YesEFO+CoLAkTQ+0NHeRCgOFIVbhg4GvbFY= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; b=h1eH4cpHQfdJs86reHD97Hww4uvZatrWTtnfhcY3LDbgpoELA2fQa2lvwcJ5MjqP7A udVyJLXwup++MNwiiluSMC5eCBvtfmntnmisdbGqR92JNDZmi67JvOqArPF23BMpVtVX gPiYv5Oh0sOfF7saXWiLpxjC9dAGBoDNp3pO8= Original-Received: by 10.210.60.3 with SMTP id i3mr900961eba.17.1232760981083; Fri, 23 Jan 2009 17:36:21 -0800 (PST) In-Reply-To: X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 2) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:108174 Archived-At: On Sat, Jan 24, 2009 at 01:52, Glenn Morris wrote: > It seems to be due to this? Yes, sorry. The problem I was fixing is that, without the patch, having a function (defun test (&optional sometimes) ...) eldoc thinks that test has two arguments, `&optional' and `sometimes'. Please try the attached fix. Juanma Index: lisp/emacs-lisp/eldoc.el =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D RCS file: /cvsroot/emacs/emacs/lisp/emacs-lisp/eldoc.el,v retrieving revision 1.56 diff -u -2 -r1.56 eldoc.el --- lisp/emacs-lisp/eldoc.el 17 Jan 2009 20:01:17 -0000 1.56 +++ lisp/emacs-lisp/eldoc.el 24 Jan 2009 01:34:05 -0000 @@ -492,8 +492,8 @@ The words \"&rest\", \"&optional\" are returned unchanged." (mapconcat (lambda (s) - (if (member s '("&optional" "&rest")) + (if (string-match-p "\\`(?&\\(?:optional\\|rest\\))?\\'" s) s (funcall eldoc-argument-case s))) - (split-string argstring "[][ ()]+" t) " ")) + (split-string argstring) " ")) =0C