update.
[chise/xemacs-chise.git-] / src / syntax.c
index 5bc68dc..f43ae57 100644 (file)
@@ -589,6 +589,11 @@ Move point forward COUNT words (backward if COUNT is negative).
 Normally t is returned, but if an edge of the buffer is reached,
 point is left there and nil is returned.
 
+The characters that are moved over may be added to the current selection
+\(i.e. active region) if the Shift key is held down, a motion key is used
+to invoke this command, and `shifted-motion-keys-select-region' is t; see
+the documentation for this variable for more details.
+
 COUNT defaults to 1, and BUFFER defaults to the current buffer.
 */
        (count, buffer))
@@ -698,7 +703,8 @@ find_start_of_comment (struct buffer *buf, Bufpos from, Bufpos stop,
                  {
                    code = Sendcomment;
                    styles_match_p =
-                     SYNTAX_CODES_COMMENT_MASK_END (prev_syncode, syncode);
+                     SYNTAX_CODES_COMMENT_MASK_END (prev_syncode, syncode)
+                     & mask;
                    from--;
                    UPDATE_SYNTAX_CACHE_BACKWARD (from);
                    c = BUF_FETCH_CHAR (buf, from);
@@ -721,7 +727,8 @@ find_start_of_comment (struct buffer *buf, Bufpos from, Bufpos stop,
                  {
                    code = Scomment;
                    styles_match_p =
-                     SYNTAX_CODES_COMMENT_MASK_START (prev_syncode, syncode);
+                     SYNTAX_CODES_COMMENT_MASK_START (prev_syncode, syncode)
+                     & mask;
                    from--;
                    UPDATE_SYNTAX_CACHE_BACKWARD (from);
                    c = BUF_FETCH_CHAR (buf, from);