(decode_coding_emacs_mule): Fix the case of
[bpt/emacs.git] / lispref / debugging.texi
index 4bc3d07..d8b465a 100644 (file)
@@ -1,6 +1,7 @@
 @c -*-texinfo-*-
 @c This is part of the GNU Emacs Lisp Reference Manual.
-@c Copyright (C) 1990, 1991, 1992, 1993, 1994, 1998 Free Software Foundation, Inc. 
+@c Copyright (C) 1990, 1991, 1992, 1993, 1994, 1998, 1999
+@c   Free Software Foundation, Inc. 
 @c See the file elisp.texi for copying conditions.
 @setfilename ../info/debugging
 @node Debugging, Read and Print, Advising Functions, Top
@@ -137,16 +138,16 @@ enter the debugger.
 @code{debug-on-error} is @code{nil}.
 @end defopt
 
-  To debug an error that happens during loading of the @file{.emacs}
-file, use the option @samp{--debug-init}, which binds
-@code{debug-on-error} to @code{t} while loading @file{.emacs}, and
+  To debug an error that happens during loading of the init
+file, use the option @samp{--debug-init}.  This binds
+@code{debug-on-error} to @code{t} while loading the init file, and
 bypasses the @code{condition-case} which normally catches errors in the
 init file.
 
-  If your @file{.emacs} file sets @code{debug-on-error}, the effect may
-not last past the end of loading @file{.emacs}.  (This is an undesirable
+  If your init file sets @code{debug-on-error}, the effect may
+not last past the end of loading the init file.  (This is an undesirable
 byproduct of the code that implements the @samp{--debug-init} command
-line option.)  The best way to make @file{.emacs} set
+line option.)  The best way to make the init file set
 @code{debug-on-error} permanently is with @code{after-init-hook}, like
 this:
 
@@ -510,9 +511,9 @@ debugger.
 
 @defvar debugger
 The value of this variable is the function to call to invoke the
-debugger.  Its value must be a function of any number of arguments (or,
-more typically, the name of a function).  Presumably this function will
-enter some kind of debugger.  The default value of the variable is
+debugger.  Its value must be a function of any number of argumentsor,
+more typically, the name of a function.  This function should invoke
+some kind of debugger.  The default value of the variable is
 @code{debug}.
 
 The first argument that Lisp hands to the function indicates why it
@@ -531,11 +532,13 @@ value is always @code{nil}.
 
 In the following example, a Lisp expression calls @code{backtrace}
 explicitly.  This prints the backtrace to the stream
-@code{standard-output}: in this case, to the buffer
-@samp{backtrace-output}.  Each line of the backtrace represents one
-function call.  The line shows the values of the function's arguments if
-they are all known.  If they are still being computed, the line says so.
-The arguments of special forms are elided.
+@code{standard-output}, which, in this case, is the buffer
+@samp{backtrace-output}.
+
+Each line of the backtrace represents one function call.  The line shows
+the values of the function's arguments if they are all known; if they
+are still being computed, the line says so.  The arguments of special
+forms are elided.
 
 @smallexample
 @group
@@ -620,9 +623,9 @@ bound to @code{nil}.  The debugger can set this variable to leave
 information for future debugger invocations during the same command
 invocation.
 
-The advantage, for the debugger, of using this variable rather than an
-ordinary global variable is that the data will never carry over to a
-subsequent command invocation.
+The advantage of using this variable rather than an ordinary global
+variable is that the data will never carry over to a subsequent command
+invocation.
 @end defvar
 
 @defun backtrace-frame frame-number
@@ -630,11 +633,11 @@ The function @code{backtrace-frame} is intended for use in Lisp
 debuggers.  It returns information about what computation is happening
 in the stack frame @var{frame-number} levels down.
 
-If that frame has not evaluated the arguments yet (or is a special
-form), the value is @code{(nil @var{function} @var{arg-forms}@dots{})}.
+If that frame has not evaluated the arguments yetor is a special
+form, the value is @code{(nil @var{function} @var{arg-forms}@dots{})}.
 
 If that frame has evaluated its arguments and called its function
-already, the value is @code{(t @var{function}
+already, the return value is @code{(t @var{function}
 @var{arg-values}@dots{})}.
 
 In the return value, @var{function} is whatever was supplied as the
@@ -679,12 +682,9 @@ find the mismatch.)
 @subsection Excess Open Parentheses
 
   The first step is to find the defun that is unbalanced.  If there is
-an excess open parenthesis, the way to do this is to insert a
-close parenthesis at the end of the file and type @kbd{C-M-b}
-(@code{backward-sexp}).  This will move you to the beginning of the
-defun that is unbalanced.  (Then type @kbd{C-@key{SPC} C-_ C-u
-C-@key{SPC}} to set the mark there, undo the insertion of the
-close parenthesis, and finally return to the mark.)
+an excess open parenthesis, the way to do this is to go to the end of
+the file and type @kbd{C-u C-M-u}.  This will move you to the beginning
+of the defun that is unbalanced.
 
   The next step is to determine precisely what is wrong.  There is no
 way to be sure of this except by studying the program, but often the
@@ -715,11 +715,9 @@ anything.
 @node Excess Close
 @subsection Excess Close Parentheses
 
-  To deal with an excess close parenthesis, first insert an open
-parenthesis at the beginning of the file, back up over it, and type
-@kbd{C-M-f} to find the end of the unbalanced defun.  (Then type
-@kbd{C-@key{SPC} C-_ C-u C-@key{SPC}} to set the mark there, undo the
-insertion of the open parenthesis, and finally return to the mark.)
+  To deal with an excess close parenthesis, first go to the beginning of
+the file, then type @kbd{C-u -1 C-M-u} to find the end of the unbalanced
+defun.
 
   Then find the actual matching close parenthesis by typing @kbd{C-M-f}
 at the beginning of that defun.  This will leave you somewhere short of
@@ -735,7 +733,7 @@ found the discrepancy, undo the @kbd{C-M-q} with @kbd{C-_}, since the
 old indentation is probably appropriate to the intended parentheses.
 
   After you think you have fixed the problem, use @kbd{C-M-q} again.  If
-the old indentation actually fit the intended nesting of parentheses,
+the old indentation actually fits the intended nesting of parentheses,
 and you have put back those parentheses, @kbd{C-M-q} should not change
 anything.