Mercurial > hg > xemacs-beta
comparison src/cmdloop.c @ 20:859a2309aef8 r19-15b93
Import from CVS: tag r19-15b93
author | cvs |
---|---|
date | Mon, 13 Aug 2007 08:50:05 +0200 |
parents | 0293115a14e9 |
children | 56c54cf7c5b6 |
comparison
equal
deleted
inserted
replaced
19:ac1f612d5250 | 20:859a2309aef8 |
---|---|
86 check_quit (); /* make Vquit_flag accurate */ | 86 check_quit (); /* make Vquit_flag accurate */ |
87 Vquit_flag = Qnil; | 87 Vquit_flag = Qnil; |
88 return (unbind_to (speccount, Qt)); | 88 return (unbind_to (speccount, Qt)); |
89 } | 89 } |
90 | 90 |
91 DEFUN ("really-early-error-handler", Freally_early_error_handler, | 91 DEFUN ("really-early-error-handler", Freally_early_error_handler, 1, 1, 0, /* |
92 Sreally_early_error_handler, 1, 1, 0 /* | |
93 You should almost certainly not be using this. | 92 You should almost certainly not be using this. |
94 */ ) | 93 */ |
95 (x) | 94 (x)) |
96 Lisp_Object x; | |
97 { | 95 { |
98 /* This is an error handler used when we're running temacs and when | 96 /* This is an error handler used when we're running temacs and when |
99 we're in the early stages of XEmacs. No errors ought to be | 97 we're in the early stages of XEmacs. No errors ought to be |
100 occurring in those cases (or they ought to be trapped and | 98 occurring in those cases (or they ought to be trapped and |
101 dealt with elsewhere), but if an error slips through, we need | 99 dealt with elsewhere), but if an error slips through, we need |
306 MARK_MODELINE_CHANGED; | 304 MARK_MODELINE_CHANGED; |
307 | 305 |
308 return Qnil; | 306 return Qnil; |
309 } | 307 } |
310 | 308 |
311 DEFUN ("recursive-edit", Frecursive_edit, Srecursive_edit, 0, 0, "" /* | 309 DEFUN ("recursive-edit", Frecursive_edit, 0, 0, "", /* |
312 Invoke the editor command loop recursively. | 310 Invoke the editor command loop recursively. |
313 To get out of the recursive edit, a command can do `(throw 'exit nil)'; | 311 To get out of the recursive edit, a command can do `(throw 'exit nil)'; |
314 that tells this function to return. | 312 that tells this function to return. |
315 Alternately, `(throw 'exit t)' makes this function signal an error. | 313 Alternately, `(throw 'exit t)' makes this function signal an error. |
316 */ ) | 314 */ |
317 () | 315 ()) |
318 { | 316 { |
319 /* This function can GC */ | 317 /* This function can GC */ |
320 Lisp_Object val; | 318 Lisp_Object val; |
321 int speccount = specpdl_depth (); | 319 int speccount = specpdl_depth (); |
322 | 320 |
470 Under the C command loop, this function will never return | 468 Under the C command loop, this function will never return |
471 (although someone might throw past it). Under the Lisp | 469 (although someone might throw past it). Under the Lisp |
472 command loop, this will return only when the user specifies | 470 command loop, this will return only when the user specifies |
473 a new command loop by changing the command-loop variable. */ | 471 a new command loop by changing the command-loop variable. */ |
474 | 472 |
475 DEFUN ("command-loop-1", Fcommand_loop_1, Scommand_loop_1, 0, 0, 0 /* | 473 DEFUN ("command-loop-1", Fcommand_loop_1, 0, 0, 0, /* |
476 Invoke the internals of the canonical editor command loop. | 474 Invoke the internals of the canonical editor command loop. |
477 Don't call this unless you know what you're doing. | 475 Don't call this unless you know what you're doing. |
478 */ ) | 476 */ |
479 () | 477 ()) |
480 { | 478 { |
481 /* This function can GC */ | 479 /* This function can GC */ |
482 Lisp_Object event = Fmake_event (); | 480 Lisp_Object event = Fmake_event (); |
483 Lisp_Object old_loop = Qnil; | 481 Lisp_Object old_loop = Qnil; |
484 struct gcpro gcpro1, gcpro2; | 482 struct gcpro gcpro1, gcpro2; |
564 defsymbol (&Qcommand_error, "command-error"); | 562 defsymbol (&Qcommand_error, "command-error"); |
565 defsymbol (&Qreally_early_error_handler, "really-early-error-handler"); | 563 defsymbol (&Qreally_early_error_handler, "really-early-error-handler"); |
566 defsymbol (&Qtop_level, "top-level"); | 564 defsymbol (&Qtop_level, "top-level"); |
567 | 565 |
568 #ifndef LISP_COMMAND_LOOP | 566 #ifndef LISP_COMMAND_LOOP |
569 defsubr (&Srecursive_edit); | 567 DEFSUBR (Frecursive_edit); |
570 #endif | 568 #endif |
571 defsubr (&Sreally_early_error_handler); | 569 DEFSUBR (Freally_early_error_handler); |
572 defsubr (&Scommand_loop_1); | 570 DEFSUBR (Fcommand_loop_1); |
573 } | 571 } |
574 | 572 |
575 void | 573 void |
576 vars_of_cmdloop (void) | 574 vars_of_cmdloop (void) |
577 { | 575 { |