all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* bug#5680: 23.1; canot quit infloop by C-g
@ 2010-03-04 15:35 ARISAWA Akihiro
  2010-03-05 23:10 ` Stefan Monnier
  0 siblings, 1 reply; 3+ messages in thread
From: ARISAWA Akihiro @ 2010-03-04 15:35 UTC (permalink / raw
  To: 5680

Hi developers,

When I evaluate following code and type C-g, I cannot quit a infinity loop.

(funcall (byte-compile (lambda () (while t))))

In emacs-22, I can quit it.

Regards,



In GNU Emacs 23.1.1 (i486-pc-linux-gnu, GTK+ Version 2.12.12)
 of 2009-10-19 on debian-build.int-office-er.priv, modified by Debian
configured using `configure  '--build=i486-linux-gnu' '--host=i486-linux-gnu' '--prefix=/usr' '--sharedstatedir=/var/lib' '--libexecdir=/usr/lib' '--localstatedir=/var/lib' '--infodir=/usr/share/info' '--mandir=/usr/share/man' '--with-pop=yes' '--enable-locallisppath=/etc/emacs23:/etc/emacs:/usr/local/share/emacs/23.1/site-lisp:/usr/local/share/emacs/site-lisp:/usr/share/emacs/23.1/site-lisp:/usr/share/emacs/site-lisp:/usr/share/emacs/23.1/leim' '--with-x=yes' '--with-x-toolkit=gtk' '--with-toolkit-scroll-bars' 'build_alias=i486-linux-gnu' 'host_alias=i486-linux-gnu' 'CFLAGS=-DDEBIAN -g -O2' 'LDFLAGS=-g' 'CPPFLAGS=''

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: ja_JP.UTF-8
  value of $XMODIFIERS: nil
  locale-coding-system: utf-8-unix
  default-enable-multibyte-characters: t

Major mode: Fundamental

Minor modes in effect:
  show-paren-mode: t
  which-function-mode: t
  icomplete-mode: t
  shell-dirtrack-mode: t
  display-time-mode: t
  tooltip-mode: t
  tool-bar-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  global-auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t
  line-number-mode: t
  transient-mark-mode: t







^ permalink raw reply	[flat|nested] 3+ messages in thread

* bug#5680: 23.1; canot quit infloop by C-g
  2010-03-04 15:35 bug#5680: 23.1; canot quit infloop by C-g ARISAWA Akihiro
@ 2010-03-05 23:10 ` Stefan Monnier
  2010-03-06  1:19   ` Stefan Monnier
  0 siblings, 1 reply; 3+ messages in thread
From: Stefan Monnier @ 2010-03-05 23:10 UTC (permalink / raw
  To: ARISAWA Akihiro; +Cc: 5680

>>>>> "ARISAWA" == ARISAWA Akihiro <ari@mbf.ocn.ne.jp> writes:

> Hi developers,
> When I evaluate following code and type C-g, I cannot quit a infinity loop.

> (funcall (byte-compile (lambda () (while t))))

> In Emacs-22, I can quit it.

Indeed, thanks.  I've just installed the patch below which should fix
this problem.


        Stefan


=== modified file 'src/bytecode.c'
--- src/bytecode.c	2010-01-13 08:35:10 +0000
+++ src/bytecode.c	2010-03-05 23:01:01 +0000
@@ -393,6 +393,7 @@
 	Fsignal (Qquit, Qnil);				\
 	AFTER_POTENTIAL_GC ();				\
       }							\
+    ELSE_PENDING_SIGNALS				\
   } while (0)
 
 

=== modified file 'src/lisp.h'
--- src/lisp.h	2010-01-22 09:10:04 +0000
+++ src/lisp.h	2010-03-05 23:03:16 +0000
@@ -1933,22 +1933,12 @@
 #ifdef SYNC_INPUT
 extern void process_pending_signals P_ ((void));
 extern int pending_signals;
-
-#define QUIT						\
-  do {							\
-    if (!NILP (Vquit_flag) && NILP (Vinhibit_quit))	\
-      {							\
-        Lisp_Object flag = Vquit_flag;			\
-	Vquit_flag = Qnil;				\
-	if (EQ (Vthrow_on_input, flag))			\
-	  Fthrow (Vthrow_on_input, Qt);			\
-	Fsignal (Qquit, Qnil);				\
-      }							\
+#define ELSE_PENDING_SIGNALS				\
     else if (pending_signals)				\
-      process_pending_signals ();			\
-  } while (0)
-
+    process_pending_signals ();
 #else  /* not SYNC_INPUT */
+#define ELSE_PENDING_SIGNALS
+#endif	/* not SYNC_INPUT */
 
 #define QUIT						\
   do {							\
@@ -1960,10 +1950,9 @@
 	  Fthrow (Vthrow_on_input, Qt);			\
 	Fsignal (Qquit, Qnil);				\
       }							\
+    ELSE_PENDING_SIGNALS				\
   } while (0)
 
-#endif	/* not SYNC_INPUT */
-
 
 /* Nonzero if ought to quit now.  */
 







^ permalink raw reply	[flat|nested] 3+ messages in thread

* bug#5680: 23.1; canot quit infloop by C-g
  2010-03-05 23:10 ` Stefan Monnier
@ 2010-03-06  1:19   ` Stefan Monnier
  0 siblings, 0 replies; 3+ messages in thread
From: Stefan Monnier @ 2010-03-06  1:19 UTC (permalink / raw
  To: ARISAWA Akihiro

> Indeed, thanks.  I've just installed the patch below which should fix
> this problem.

Forgot to close it, sorry,


        Stefan






^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2010-03-06  1:19 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-03-04 15:35 bug#5680: 23.1; canot quit infloop by C-g ARISAWA Akihiro
2010-03-05 23:10 ` Stefan Monnier
2010-03-06  1:19   ` Stefan Monnier

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.