aboutsummaryrefslogtreecommitdiffstats
path: root/src/syntax.c
diff options
context:
space:
mode:
authorJoakim Verona2012-08-19 02:44:11 +0200
committerJoakim Verona2012-08-19 02:44:11 +0200
commit5436d1df5e2ba0b4d4f72b03a1cd09b20403654b (patch)
tree532faa27319b3bb199d414dc85e63a58246d30b0 /src/syntax.c
parentd02344322b0d2fea8dd9ad9dd0a6c70e058f967b (diff)
parente757f1c6f393cf82057dbee0a4325b07f0fd55c4 (diff)
downloademacs-5436d1df5e2ba0b4d4f72b03a1cd09b20403654b.tar.gz
emacs-5436d1df5e2ba0b4d4f72b03a1cd09b20403654b.zip
upstream
Diffstat (limited to 'src/syntax.c')
-rw-r--r--src/syntax.c12
1 files changed, 9 insertions, 3 deletions
diff --git a/src/syntax.c b/src/syntax.c
index 08a63e033b2..f995b8f2cac 100644
--- a/src/syntax.c
+++ b/src/syntax.c
@@ -20,7 +20,6 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
20 20
21#include <config.h> 21#include <config.h>
22 22
23#include <ctype.h>
24#include <sys/types.h> 23#include <sys/types.h>
25#include <setjmp.h> 24#include <setjmp.h>
26#include "lisp.h" 25#include "lisp.h"
@@ -150,6 +149,13 @@ static void scan_sexps_forward (struct lisp_parse_state *,
150 ptrdiff_t, ptrdiff_t, ptrdiff_t, EMACS_INT, 149 ptrdiff_t, ptrdiff_t, ptrdiff_t, EMACS_INT,
151 int, Lisp_Object, int); 150 int, Lisp_Object, int);
152static int in_classes (int, Lisp_Object); 151static int in_classes (int, Lisp_Object);
152
153/* This setter is used only in this file, so it can be private. */
154static inline void
155bset_syntax_table (struct buffer *b, Lisp_Object val)
156{
157 b->INTERNAL_FIELD (syntax_table) = val;
158}
153 159
154/* Whether the syntax of the character C has the prefix flag set. */ 160/* Whether the syntax of the character C has the prefix flag set. */
155int syntax_prefix_flag_p (int c) 161int syntax_prefix_flag_p (int c)
@@ -819,7 +825,7 @@ It is a copy of the TABLE, which defaults to the standard syntax table. */)
819 825
820 /* Only the standard syntax table should have a default element. 826 /* Only the standard syntax table should have a default element.
821 Other syntax tables should inherit from parents instead. */ 827 Other syntax tables should inherit from parents instead. */
822 XCHAR_TABLE (copy)->defalt = Qnil; 828 set_char_table_defalt (copy, Qnil);
823 829
824 /* Copied syntax tables should all have parents. 830 /* Copied syntax tables should all have parents.
825 If we copied one with no parent, such as the standard syntax table, 831 If we copied one with no parent, such as the standard syntax table,
@@ -836,7 +842,7 @@ One argument, a syntax table. */)
836{ 842{
837 int idx; 843 int idx;
838 check_syntax_table (table); 844 check_syntax_table (table);
839 BSET (current_buffer, syntax_table, table); 845 bset_syntax_table (current_buffer, table);
840 /* Indicate that this buffer now has a specified syntax table. */ 846 /* Indicate that this buffer now has a specified syntax table. */
841 idx = PER_BUFFER_VAR_IDX (syntax_table); 847 idx = PER_BUFFER_VAR_IDX (syntax_table);
842 SET_PER_BUFFER_VALUE_P (current_buffer, idx, 1); 848 SET_PER_BUFFER_VALUE_P (current_buffer, idx, 1);