bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

find-function-regexp


From: Jonas Lindström
Subject: find-function-regexp
Date: Tue, 12 Jun 2001 14:56:56 +0200 (MEST)

This bug report will be sent to the Free Software Foundation,
 not to your local site managers!!
Please write in English, because the Emacs maintainers do not have
translators to read other languages for them.

In GNU Emacs 20.7.1 (i386-*-nt4.0.1381)
 of Tue Jun 13 2000 on buffy
configured using `configure NT'

Please describe exactly what actions triggered the bug
and the precise symptoms of the bug:

`find-function-regexp' does not match a function definition where there is no
whitespace between the name of the function and the argument list.

To reproduce, take any old Lisp function in your load-path or .emacs and
remove the whitespace before the argument list:

(defun foo(x)     ;; No whitespace between foo and (x)
  "Return 1 + x."
  (1+ x))

M-x find-function <RET> foo <RET>

gives an error message

Cannot find definition of `foo' in library `u:/.emacs' [2 times]

As far as I understand, the function definition above is correct (albeit not
good Lisp style). A straightforward solution is to change find-function-regexp
to match a left-paren after the function name as well.

find-function-regexp will still lose in some abnormal cases, for instance if
someone defines the function `foo\(', but fixing that seems like overkill,
IMO.

/Jonas L


Recent input:
return down down down down down down down down down 
down down down down left left left left left left left 
left left up left left left left left left left left 
left left left left down right home left left left 
left left left left left left ( delete \ | down left 
left left left down right up right right right right 
up right right right right return 0 C-< M-x up C-g 
C-< M-x up return up up return f5 end left left left 
SPC down M-x up return up return C-_ C-x C-b menu-bar 
help-menu report-emacs-bug

Recent messages:
Making completion list...
Creating customization buffer...
Creating customization buttons...
Creating customization items...
Creating customization items ...100%done
Creating customization setup...
Creating customization buffer...done
Quit
Mark set [2 times]
Undo!




reply via email to

[Prev in Thread] Current Thread [Next in Thread]