From d2de5265221871271e85a6838c6ec7aa0226da94 Mon Sep 17 00:00:00 2001 From: TEC Date: Fri, 8 Mar 2024 00:23:27 +0800 Subject: [PATCH] Don't set invalid text properties --- simple-comment-markup.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/simple-comment-markup.el b/simple-comment-markup.el index 9d444f6..3a79679 100644 --- a/simple-comment-markup.el +++ b/simple-comment-markup.el @@ -158,7 +158,7 @@ This must not include any capturing groups." (not (re-search-forward (rx point (syntax comment-start)) nil t)))))))))) - (when multiline + (when (and multiline (< markup-start markup-end)) (put-text-property markup-start markup-end 'font-lock-multiline t)) (set-match-data (and markup-start (list markup-start markup-end)))))