summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRichard M. Stallman <rms@gnu.org>1998-08-10 21:19:03 +0000
committerRichard M. Stallman <rms@gnu.org>1998-08-10 21:19:03 +0000
commit3ed02ac59a16157103825a97b7b7f99d48c3724a (patch)
tree25035eed4fc49f69e789ee7b25c899de328fd8ae
parent852b069a73be360fb7781c83937eb76286207228 (diff)
downloademacs-3ed02ac59a16157103825a97b7b7f99d48c3724a.tar.gz
(scan_sexps_forward): Set up the syntax table scanning
stuff before jumping into the loop.
-rw-r--r--src/syntax.c14
1 files changed, 10 insertions, 4 deletions
diff --git a/src/syntax.c b/src/syntax.c
index b17a8d4d0bc..4edac655b7f 100644
--- a/src/syntax.c
+++ b/src/syntax.c
@@ -2383,17 +2383,23 @@ do { prev_from = from; \
curlevel->prev = -1;
curlevel->last = -1;
+ SETUP_SYNTAX_TABLE (prev_from, 1);
+ prev_from_syntax = SYNTAX_WITH_FLAGS (FETCH_CHAR (prev_from_byte));
+ UPDATE_SYNTAX_TABLE_FORWARD (from);
+
/* Enter the loop at a place appropriate for initial state. */
- if (state.incomment) goto startincomment;
+ if (state.incomment)
+ goto startincomment;
if (state.instring >= 0)
{
nofence = state.instring != ST_STRING_STYLE;
- if (start_quoted) goto startquotedinstring;
+ if (start_quoted)
+ goto startquotedinstring;
goto startinstring;
}
- if (start_quoted) goto startquoted;
-
+ else if (start_quoted)
+ goto startquoted;
SETUP_SYNTAX_TABLE (prev_from, 1);
prev_from_syntax = SYNTAX_WITH_FLAGS (FETCH_CHAR (prev_from_byte));