Commit 0f867324 authored by Richard M. Stallman's avatar Richard M. Stallman
Browse files

(Fcopy_syntax_table): Set default to nil.

Set the parent only if it was nil.
parent 3efb840d
......@@ -163,7 +163,16 @@ It is a copy of the TABLE, which defaults to the standard syntax table.")
table = Vstandard_syntax_table;
copy = Fcopy_sequence (table);
Fset_char_table_parent (copy, Vstandard_syntax_table);
/* Only the standard syntax table should have a default element.
Other syntax tables should inherit from parents instead. */
XCHAR_TABLE (copy)->defalt = Qnil;
/* Copied syntax tables should all have parents.
If we copied one with no parent, such as the standard syntax table,
use the standard syntax table as the copy's parent. */
if (NILP (XCHAR_TABLE (copy)->parent))
Fset_char_table_parent (copy, Vstandard_syntax_table);
return copy;
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment