rms@prep.ai.mit.edu (01/29/86)
From: rms@prep.ai.mit.edu (Richard M. Stallman)
Two files, src/syntax.c and lisp/texinfo.el, were given wrongly
in the diffs distributed until now from 17.36 to 17.43.
Here are the correct differences for those two files.
The file of diffs, /u2/emacs/diff-17.36-17.43, has been corrected.
syntax.c==============================
*** oodist/src/syntax.c Thu Dec 12 22:06:00 1985
--- dist/src/syntax.c Tue Jan 14 01:18:24 1986
***************
*** 41,46
return Qnil;
}
DEFUN ("syntax-table", Fsyntax_table, Ssyntax_table, 0, 0, 0,
"Return the current syntax table.\n\
This is the one specified by the current buffer.")
--- 41,58 -----
return Qnil;
}
+ Lisp_Object
+ check_syntax_table (obj)
+ Lisp_Object obj;
+ {
+ register Lisp_Object tem;
+ while (tem = Fsyntax_table_p (obj),
+ NULL (tem))
+ obj = wrong_type_argument (Qsyntax_table_p, obj, 0);
+ return obj;
+ }
+
+
DEFUN ("syntax-table", Fsyntax_table, Ssyntax_table, 0, 0, 0,
"Return the current syntax table.\n\
This is the one specified by the current buffer.")
***************
*** 60,66
return Vstandard_syntax_table;
}
! DEFUN ("make-syntax-table", Fmake_syntax_table, Smake_syntax_table, 0, 0, 0,
"Construct a new syntax table and return it.\n\
It is a copy of the standard syntax table's current contents.")
()
--- 72,78 -----
return Vstandard_syntax_table;
}
! DEFUN ("copy-syntax-table", Fcopy_syntax_table, Scopy_syntax_table, 0, 1, 0,
"Construct a new syntax table and return it.\n\
It is a copy of the TABLE, which defaults to the standard syntax table.")
(table)
***************
*** 62,69
DEFUN ("make-syntax-table", Fmake_syntax_table, Smake_syntax_table, 0, 0, 0,
"Construct a new syntax table and return it.\n\
! It is a copy of the standard syntax table's current contents.")
! ()
{
Lisp_Object size, val;
XFASTINT (size) = 0400;
--- 74,82 -----
DEFUN ("copy-syntax-table", Fcopy_syntax_table, Scopy_syntax_table, 0, 1, 0,
"Construct a new syntax table and return it.\n\
! It is a copy of the TABLE, which defaults to the standard syntax table.")
! (table)
! Lisp_Object table;
{
Lisp_Object size, val;
XFASTINT (size) = 0400;
***************
*** 69,77
XFASTINT (size) = 0400;
XFASTINT (val) = 0;
val = Fmake_vector (size, val);
! if (!NULL (Vstandard_syntax_table))
! bcopy (XVECTOR (Vstandard_syntax_table)->contents,
! XVECTOR (val)->contents, 0400 * sizeof (Lisp_Object));
return val;
}
--- 82,96 -----
XFASTINT (size) = 0400;
XFASTINT (val) = 0;
val = Fmake_vector (size, val);
! if (!NULL (table))
! table = check_syntax_table (table);
! else if (NULL (Vstandard_syntax_table))
! /* Can only be null during initialization */
! return val;
! else table = Vstandard_syntax_table;
!
! bcopy (XVECTOR (table)->contents,
! XVECTOR (val)->contents, 0400 * sizeof (Lisp_Object));
return val;
}
***************
*** 75,82
return val;
}
! DEFUN ("set-syntax-table", Fset_syntax_table, Sset_syntax_table, 1, 1,
! "sSet syntax table: ",
"Select a new syntax table for the current buffer.\n\
One argument, a syntax table.")
(table)
--- 94,100 -----
return val;
}
! DEFUN ("set-syntax-table", Fset_syntax_table, Sset_syntax_table, 1, 1, 0,
"Select a new syntax table for the current buffer.\n\
One argument, a syntax table.")
(table)
***************
*** 82,93
(table)
Lisp_Object table;
{
! register Lisp_Object tem;
!
! tem = Fsyntax_table_p (table);
! if (NULL (tem))
! table = wrong_type_argument (Qsyntax_table_p, table, 0);
!
bf_cur->syntax_table_v = XVECTOR (table);
return table;
}
--- 100,106 -----
(table)
Lisp_Object table;
{
! table = check_syntax_table (table);
bf_cur->syntax_table_v = XVECTOR (table);
return table;
}
***************
*** 137,143
return make_number (syntax_code_spec[(int) SYNTAX (XINT (ch))]);
}
! DEFUN ("modify-syntax-entry", Fmodify_syntax_entry, Smodify_syntax_entry, 2, 2,
"cSet syntax for character: \nsSet syntax for %s to: ",
0 /* See auxdoc.c */)
(c, newentry)
--- 150,159 -----
return make_number (syntax_code_spec[(int) SYNTAX (XINT (ch))]);
}
! DEFUN ("modify-syntax-entry", Fmodify_syntax_entry, Smodify_syntax_entry, 2, 3,
! /* I really don't know why this is interactive
! help-form should at least be made useful whilst reading the second arg
! */
"cSet syntax for character: \nsSet syntax for %s to: ",
0 /* See auxdoc.c */)
(c, newentry, syntax_table)
***************
*** 140,147
DEFUN ("modify-syntax-entry", Fmodify_syntax_entry, Smodify_syntax_entry, 2, 2,
"cSet syntax for character: \nsSet syntax for %s to: ",
0 /* See auxdoc.c */)
! (c, newentry)
! Lisp_Object c, newentry;
{
register unsigned char *p, match;
register enum syntaxcode code;
--- 156,163 -----
*/
"cSet syntax for character: \nsSet syntax for %s to: ",
0 /* See auxdoc.c */)
! (c, newentry, syntax_table)
! Lisp_Object c, newentry, syntax_table;
{
register unsigned char *p, match;
register enum syntaxcode code;
***************
*** 149,154
CHECK_NUMBER (c, 0);
CHECK_STRING (newentry, 1);
p = XSTRING (newentry)->data;
code = (enum syntaxcode) syntax_spec_code[*p++];
--- 165,173 -----
CHECK_NUMBER (c, 0);
CHECK_STRING (newentry, 1);
+ if (NULL (syntax_table))
+ XSET (syntax_table, Lisp_Vector, bf_cur->syntax_table_v);
+ else syntax_table = check_syntax_table (syntax_table);
p = XSTRING (newentry)->data;
code = (enum syntaxcode) syntax_spec_code[*p++];
***************
*** 153,159
p = XSTRING (newentry)->data;
code = (enum syntaxcode) syntax_spec_code[*p++];
if (((int) code & 0377) == 0377)
! error ("invalid syntax description letter", c);
match = *p++;
if (match == ' ') match = 0;
--- 172,178 -----
p = XSTRING (newentry)->data;
code = (enum syntaxcode) syntax_spec_code[*p++];
if (((int) code & 0377) == 0377)
! error ("invalid syntax description letter: %c", c);
match = *p++;
if (match == ' ') match = 0;
***************
*** 179,185
break;
}
! bf_cur->syntax_table_v->contents[XINT (c)] = val;
return Qnil;
}
--- 198,204 -----
break;
}
! XVECTOR (syntax_table)->contents[XINT (c)] = val;
return Qnil;
}
***************
*** 970,977
register struct Lisp_Vector *v;
/* Set this now, so first buffer creation can refer to it. */
! /* Make it nil before calling make-syntax-table
! so that make-syntax-table will know not to try to copy from garbage */
Vstandard_syntax_table = Qnil;
Vstandard_syntax_table = Fmake_syntax_table ();
--- 989,996 -----
register struct Lisp_Vector *v;
/* Set this now, so first buffer creation can refer to it. */
! /* Make it nil before calling copy-syntax-table
! so that copy-syntax-table will know not to try to copy from garbage */
Vstandard_syntax_table = Qnil;
Vstandard_syntax_table = Fcopy_syntax_table (Qnil);
***************
*** 973,979
/* Make it nil before calling make-syntax-table
so that make-syntax-table will know not to try to copy from garbage */
Vstandard_syntax_table = Qnil;
! Vstandard_syntax_table = Fmake_syntax_table ();
v = XVECTOR (Vstandard_syntax_table);
--- 992,998 -----
/* Make it nil before calling copy-syntax-table
so that copy-syntax-table will know not to try to copy from garbage */
Vstandard_syntax_table = Qnil;
! Vstandard_syntax_table = Fcopy_syntax_table (Qnil);
v = XVECTOR (Vstandard_syntax_table);
***************
*** 1023,1029
defsubr (&Ssyntax_table_p);
defsubr (&Ssyntax_table);
defsubr (&Sstandard_syntax_table);
! defsubr (&Smake_syntax_table);
defsubr (&Sset_syntax_table);
defsubr (&Schar_syntax);
defsubr (&Smodify_syntax_entry);
--- 1042,1048 -----
defsubr (&Ssyntax_table_p);
defsubr (&Ssyntax_table);
defsubr (&Sstandard_syntax_table);
! defsubr (&Scopy_syntax_table);
defsubr (&Sset_syntax_table);
defsubr (&Schar_syntax);
defsubr (&Smodify_syntax_entry);
lisp/texinfo.el==============================
*** oodist/lisp/texinfo.el Wed Dec 18 21:59:42 1985
--- dist/lisp/texinfo.el Thu Jan 23 13:15:35 1986
***************
*** 128,134
(skip-chars-backward "\^Q")
(= (logand 1 (- opoint (point))) 1))))
nil
! (if (looking-at "[@{}'`]")
(progn
(delete-char -1)
(forward-char 1))
--- 128,134 -----
(skip-chars-backward "\^Q")
(= (logand 1 (- opoint (point))) 1))))
nil
! (if (looking-at "[@{}'` ]")
(progn
(delete-char -1)
(forward-char 1))
***************
*** 240,245
(put 'setfilename 'texinfo-format 'texinfo-format-setfilename)
(defun texinfo-format-setfilename ()
(let ((arg (texinfo-parse-arg-discard)))
(insert "Info file "
arg
", produced by texinfo-format-buffer -*-Text-*-\nfrom "
--- 240,246 -----
(put 'setfilename 'texinfo-format 'texinfo-format-setfilename)
(defun texinfo-format-setfilename ()
(let ((arg (texinfo-parse-arg-discard)))
+ (setq texinfo-format-filename (file-name-nondirectory arg))
(insert "Info file "
texinfo-format-filename
", produced by texinfo-format-buffer -*-Text-*-\nfrom "
***************
*** 241,247
(defun texinfo-format-setfilename ()
(let ((arg (texinfo-parse-arg-discard)))
(insert "Info file "
! arg
", produced by texinfo-format-buffer -*-Text-*-\nfrom "
(if (buffer-file-name input-buffer)
(concat "file "
--- 242,248 -----
(let ((arg (texinfo-parse-arg-discard)))
(setq texinfo-format-filename (file-name-nondirectory arg))
(insert "Info file "
! texinfo-format-filename
", produced by texinfo-format-buffer -*-Text-*-\nfrom "
(if (buffer-file-name input-buffer)
(concat "file "
***************
*** 247,254
(concat "file "
(file-name-nondirectory (buffer-file-name input-buffer)))
(concat "buffer " (buffer-name input-buffer)))
! ?\n)
! (setq texinfo-format-filename (file-name-nondirectory arg))))
(put 'node 'texinfo-format 'texinfo-format-node)
(defun texinfo-format-node ()
--- 248,254 -----
(concat "file "
(file-name-nondirectory (buffer-file-name input-buffer)))
(concat "buffer " (buffer-name input-buffer)))
! ?\n)))
(put 'node 'texinfo-format 'texinfo-format-node)
(defun texinfo-format-node ()