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

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

[debbugs-tracker] bug#10797: closed (24.0.93; end-of-defun goes into inf


From: GNU bug Tracking System
Subject: [debbugs-tracker] bug#10797: closed (24.0.93; end-of-defun goes into infinite mutual recursion with beginning-of-defun-raw at certain conditions)
Date: Thu, 23 Feb 2012 08:18:02 +0000

Your message dated Thu, 23 Feb 2012 03:14:23 -0500
with message-id <address@hidden>
and subject line Re: bug#10797: 24.0.93; end-of-defun goes into infinite mutual 
recursion with beginning-of-defun-raw at certain conditions
has caused the debbugs.gnu.org bug report #10797,
regarding 24.0.93; end-of-defun goes into infinite mutual recursion with 
beginning-of-defun-raw at certain conditions
to be marked as done.

(If you believe you have received this mail in error, please contact
address@hidden)


-- 
10797: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=10797
GNU Bug Tracking System
Contact address@hidden with problems
--- Begin Message --- Subject: 24.0.93; end-of-defun goes into infinite mutual recursion with beginning-of-defun-raw at certain conditions Date: Sun, 12 Feb 2012 18:19:22 +0400 User-agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:9.0) Gecko/20111222 Thunderbird/9.0.1
Main condition: the beginning-of-defun-function must not take an
argument. So the "compatibility" path at `beginning-of-defun-raw'
is taken (lines 256-262).

If point is at such position in buffer that

(progn (funcall 'beginning-of-defun-function)
       (funcall 'end-of-defun-function))

doesn't move it lower in the buffer, then the (end-of-defun (- arg))
call in `beginning-of-defun-raw' eventually results in
"Lisp nesting exceeds `max-lisp-eval-depth'".

Example (the buffer must be in python-mode):

def abc:
    return

.a = 2

def cde:
    return

The point is at the position denoted by ".". After pressing C-M-e, I reliably see the error message above. Same thing if I move the point forward one line.

Patch attached.

By the way, that comment was wrong (see patch) - `end-of-defun' doesn't check whether end-of-defun-function is defined, and fails if it's not.


In GNU Emacs 24.0.93.1 (i386-mingw-nt6.1.7601)
 of 2012-02-09 on SOL
Windowing system distributor `Microsoft Corp.', version 6.1.7601
Configured using:
 `configure --with-gcc (3.4) --cflags -IH:/Apps/System/gnuwin32/include'

Important settings:
  value of $LC_ALL: nil
  value of $LC_COLLATE: nil
  value of $LC_CTYPE: nil
  value of $LC_MESSAGES: nil
  value of $LC_MONETARY: nil
  value of $LC_NUMERIC: nil
  value of $LC_TIME: nil
  value of $LANG: RU
  value of $XMODIFIERS: nil
  locale-coding-system: cp1251
  default enable-multibyte-characters: t

Major mode: Python

Minor modes in effect:
  subword-mode: t
  hl-line-mode: t
  global-auto-revert-mode: t
  cua-mode: t
  global-auto-complete-mode: t
  auto-complete-mode: t
  autopair-mode: t
  autopair-global-mode: t
  yas/global-mode: t
  yas/minor-mode: t
  ido-ubiquitous-mode: t
  ido-everywhere: t
  show-paren-mode: t
  mouse-wheel-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t
  column-number-mode: t
  line-number-mode: t
  transient-mark-mode: t

Recent input:
<down-mouse-1> <mouse-1> M-x p y t h o n <return> C-y
<up> <up> <up> <home> C-M-e <down> <down> <down> <down>
C-M-e <down-mouse-1> <mouse-1> <home> M-x r e p o r
t <return> e n d - o f - e <backspace> d e f u n <return>
<down-mouse-1> <mouse-1> <help-echo> <down-mouse-1>
<mouse-1> <help-echo> <down-mouse-1> <mouse-1> <help-echo>
<down> <down> <down> <down> <down> <right> <right>
<right> <right> <right> <right> <return> <left> <up>
<left> <left> <left> SPC <left> SPC <return> <down>
<right> <right> <right> <right> <right> <return> <down>
<down> <right> <right> <right> <right> <right> <right>
<right> <right> <return> q <down> <down> <end> <left>
<left> <return> <down-mouse-1> <mouse-1> <down-mouse-1>
<mouse-1> <help-echo> <up> <up> <up> <up> <up> <end>
<backspace> <backspace> <up> <home> <tab> <down> <tab>
<tab> <tab> <tab> <down> <down> <tab> <down> <down>
<tab> <down> <tab> <tab> <tab> <tab> <down> <down>
<down> <return> <tab> <tab> <up> <up> <up> <up> C-M-e
<down> <down> <down> <down> C-M-e <down> <down> <down>
<down> <down> C-M-e <up> <up> <up> <up> C-M-e <down>
<down> <down> M-x r e p o r t <right> <return>

Recent messages:
widget-apply-action: Attempt to perform action on inactive widget
call-interactively: Buffer is read-only: #<buffer *Existing Emacs Bugs*>
Sole indentation [6 times]
byte-code: End of buffer [3 times]
Sole indentation
Mark set [198 times]
syntax-ppss: Lisp nesting exceeds `max-lisp-eval-depth'
Mark set [198 times]
syntax-ppss: Lisp nesting exceeds `max-lisp-eval-depth'
Mark set [199 times]
syntax-ppss: Lisp nesting exceeds `max-lisp-eval-depth'

Load-path shadows:
None found.

Features:
(shadow sort flyspell ispell mail-extr message format-spec rfc822 mml
mml-sec mm-decode mm-bodies mm-encode mailabbrev gmm-utils mailheader
browse-url wid-edit mail-utils url-cache network-stream starttls
url-http tls mail-parse rfc2231 rfc2047 rfc2045 ietf-drums url-gw
url-auth url url-proxy url-privacy url-expand url-methods url-history
url-cookie url-util url-parse auth-source eieio byte-opt bytecomp
byte-compile cconv macroexp gnus-util password-cache url-vars mm-util
mail-prsvr mailcap emacsbug subword python-21 python ansi-color comint
elisp-slime-nav etags paredit hl-line saveplace autorevert cua-base
winner .emacs-loaddefs server devenv switch-window quail point-stack
pos-tip ac-slime auto-complete-config auto-complete popup
eproject-extras ibuf-ext ibuffer iswitchb eproject esh-var esh-io
esh-cmd esh-ext esh-proc esh-arg eldoc esh-groups eshell esh-module
esh-mode esh-util progmodes mmm rhtml-sgml-hacks rhtml-ruby-hook
ruby-mode sgml-mode rhtml-erb mmm-auto mmm-vars mmm-compat regexp-opt
ecb-autoloads autopair yasnippet-bundle dropdown-list yasnippet derived
easy-mmode help-mode view easymenu assoc keys winring ring
transpose-frame iflipb redo+ misc prefs defuns eldoc-eval-autoloads
findr-autoloads gist-autoloads highlight-symbol-autoloads
inf-ruby-autoloads inflections-autoloads move-text-autoloads
ruby-electric-autoloads starter-kit-bindings-autoloads windmove
starter-kit-lisp-autoloads elisp-slime-nav-autoloads
starter-kit-autoloads edmacro kmacro smex cl starter-kit-misc
ido-ubiquitous ido paren starter-kit-defuns uniquify advice help-fns
advice-preload magit-autoloads ido-ubiquitous-autoloads smex-autoloads
find-file-in-project-autoloads idle-highlight-mode-autoloads
paredit-autoloads switch-window-autoloads yaml-mode-autoloads package
tabulated-list time-date tooltip ediff-hook vc-hooks lisp-float-type
mwheel dos-w32 disp-table ls-lisp w32-win w32-vars tool-bar dnd fontset
image fringe lisp-mode register page menu-bar rfn-eshadow timer select
scroll-bar mouse jit-lock font-lock syntax facemenu font-core frame cham
georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao
korean japanese hebrew greek romanian slovak czech european ethiopic
indian cyrillic chinese case-table epa-hook jka-cmpr-hook help simple
abbrev minibuffer button faces cus-face files text-properties overlay
sha1 md5 base64 format env code-pages mule custom widget
hashtable-print-readable backquote make-network-process multi-tty emacs)

Attachment: beginning-of-defun-raw-patch.diff
Description: Text document


--- End Message ---
--- Begin Message --- Subject: Re: bug#10797: 24.0.93; end-of-defun goes into infinite mutual recursion with beginning-of-defun-raw at certain conditions Date: Thu, 23 Feb 2012 03:14:23 -0500 User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.93 (gnu/linux)
> -         ;; Better not call end-of-defun-function directly, in case
> -         ;; it's not defined.
> -         (end-of-defun (- arg))))))
> +      (dotimes (i (- arg))
> +        (funcall end-of-defun-function))))))
 
Looks good, installed,
Thank you,


        Stefan


--- End Message ---

reply via email to

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