(forward-comment -n): escaped newline is sometimes NOT end of comment

* src/syntax.c (Fforward_comment) When comment-end-can-be-escaped is non-nil,
don't attempt back_comment when point is just after an escaped newline, etc.
This commit is contained in:
Alan Mackenzie 2020-04-16 17:01:14 +00:00
parent 0127118c25
commit 22ba047420

View file

@ -2572,8 +2572,9 @@ between them, return t; otherwise return nil. */)
}
else if (code == Sendcomment)
{
found = back_comment (from, from_byte, stop, comnested, comstyle,
&out_charpos, &out_bytepos);
found = (!quoted || !Vcomment_end_can_be_escaped)
&& back_comment (from, from_byte, stop, comnested, comstyle,
&out_charpos, &out_bytepos);
if (!found)
{
if (c == '\n')