Mercurial > emacs
comparison src/syntax.c @ 18613:614b916ff5bf
Fix bugs with inappropriate mixing of Lisp_Object with int.
author | Richard M. Stallman <rms@gnu.org> |
---|---|
date | Fri, 04 Jul 1997 20:44:52 +0000 |
parents | bf0d449581c8 |
children | bcc43754d3bc |
comparison
equal
deleted
inserted
replaced
18612:88efccff8970 | 18613:614b916ff5bf |
---|---|
188 } | 188 } |
189 } | 189 } |
190 | 190 |
191 gl_state.current_syntax_table = tmp_table; | 191 gl_state.current_syntax_table = tmp_table; |
192 gl_state.old_prop = tmp_table; | 192 gl_state.old_prop = tmp_table; |
193 if (Fsyntax_table_p (tmp_table) == Qt) | 193 if (EQ (Fsyntax_table_p (tmp_table), Qt)) |
194 { | 194 { |
195 gl_state.use_global = 0; | 195 gl_state.use_global = 0; |
196 } | 196 } |
197 else if (CONSP (tmp_table)) | 197 else if (CONSP (tmp_table)) |
198 { | 198 { |
663 gl_state.use_global = 0; | 663 gl_state.use_global = 0; |
664 CHECK_NUMBER (character, 0); | 664 CHECK_NUMBER (character, 0); |
665 char_int = XINT (character); | 665 char_int = XINT (character); |
666 code = SYNTAX (char_int); | 666 code = SYNTAX (char_int); |
667 if (code == Sopen || code == Sclose) | 667 if (code == Sopen || code == Sclose) |
668 return make_number (SYNTAX_MATCH (char_int)); | 668 return SYNTAX_MATCH (char_int); |
669 return Qnil; | 669 return Qnil; |
670 } | 670 } |
671 | 671 |
672 /* This comment supplies the doc string for modify-syntax-entry, | 672 /* This comment supplies the doc string for modify-syntax-entry, |
673 for make-docfile to see. We cannot put this in the real DEFUN | 673 for make-docfile to see. We cannot put this in the real DEFUN |
733 check_syntax_table (syntax_table); | 733 check_syntax_table (syntax_table); |
734 | 734 |
735 p = XSTRING (newentry)->data; | 735 p = XSTRING (newentry)->data; |
736 code = (enum syntaxcode) syntax_spec_code[*p++]; | 736 code = (enum syntaxcode) syntax_spec_code[*p++]; |
737 if (((int) code & 0377) == 0377) | 737 if (((int) code & 0377) == 0377) |
738 error ("invalid syntax description letter: %c", XINT (c)); | 738 error ("invalid syntax description letter: %c", p[-1]); |
739 | 739 |
740 if (code == Sinherit) | 740 if (code == Sinherit) |
741 { | 741 { |
742 SET_RAW_SYNTAX_ENTRY (syntax_table, XINT (c), Qnil); | 742 SET_RAW_SYNTAX_ENTRY (syntax_table, XINT (c), Qnil); |
743 return Qnil; | 743 return Qnil; |