Wed, 10 Jul 2024 21:57:53 +0200
hotfix for multiple subsequent line continuations
issue #392
src/highlighter.c | file | annotate | diff | comparison | revisions |
--- a/src/highlighter.c Wed Jul 10 21:35:37 2024 +0200 +++ b/src/highlighter.c Wed Jul 10 21:57:53 2024 +0200 @@ -130,15 +130,15 @@ /* continue highlighting in case of line continuation */ if (hd->continue_highlight) { start_span(hd->continue_highlight); - hd->continue_highlight = NULL; isinclude = hd->continuation_info & 0x1; - isstring = hd->continuation_info & 0x2; - iscomment = hd->continuation_info & 0x4; + isstring = (hd->continuation_info & 0x2) >> 1; + iscomment = (hd->continuation_info & 0x4) >> 2; if (hd->continuation_info & 0x10) { quote = '\''; } else if (hd->continuation_info & 0x20) { quote = '\"'; } + hd->continue_highlight = NULL; hd->continuation_info = 0; }