Mercurial > vim
annotate runtime/syntax/web.vim @ 34257:8a91d18f1789 v9.1.0069
patch 9.1.0069: ScreenLines may not be correctly initialized, causing hang
Commit: https://github.com/vim/vim/commit/fd472655a93fd539c731c8daf3adc4e65ddce341
Author: Olaf Seibert <rhialto@falu.nl>
Date: Thu Feb 1 21:11:16 2024 +0100
patch 9.1.0069: ScreenLines may not be correctly initialized, causing hang
Problem: ScreenLines may not be correctly initialized, causing hang
(Olaf Seibert, after 9.0.0220)
Solution: always initialize ScreneLines when allocating a screen
(Olaf Seibert)
ScreenLines and related structures could be left uninitialized
causing a screen update to run into an infinite loop when using latin1
encoding.
Partly caused because by patch 9.0.0220, which makes mb_ptr2len return
zero for NUL
related: #12671
closes: #13946
Signed-off-by: Olaf Seibert <rhialto@falu.nl>
Signed-off-by: Christian Brabandt <cb@256bit.org>
author | Christian Brabandt <cb@256bit.org> |
---|---|
date | Thu, 01 Feb 2024 21:30:02 +0100 |
parents | 43efa4f5a8ea |
children |
rev | line source |
---|---|
7 | 1 " Vim syntax file |
2 " Language: WEB | |
3 " Maintainer: Andreas Scherer <andreas.scherer@pobox.com> | |
4 " Last Change: April 30, 2001 | |
5 | |
6 " Details of the WEB language can be found in the article by Donald E. Knuth, | |
7 " "The WEB System of Structured Documentation", included as "webman.tex" in | |
8 " the standard WEB distribution, available for anonymous ftp at | |
9 " ftp://labrea.stanford.edu/pub/tex/web/. | |
10 | |
10048
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
7
diff
changeset
|
11 " quit when a syntax file was already loaded |
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
7
diff
changeset
|
12 if exists("b:current_syntax") |
7 | 13 finish |
14 endif | |
15 | |
16 " Although WEB is the ur-language for the "Literate Programming" paradigm, | |
17 " we base this syntax file on the modern superset, CWEB. Note: This shortcut | |
18 " may introduce some illegal constructs, e.g., CWEB's "@c" does _not_ start a | |
19 " code section in WEB. Anyway, I'm not a WEB programmer. | |
10048
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
7
diff
changeset
|
20 runtime! syntax/cweb.vim |
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
7
diff
changeset
|
21 unlet b:current_syntax |
7 | 22 |
23 " Replace C/C++ syntax by Pascal syntax. | |
24 syntax include @webIncludedC <sfile>:p:h/pascal.vim | |
25 | |
26 " Double-@ means single-@, anywhere in the WEB source (as in CWEB). | |
27 " Don't misinterpret "@'" as the start of a Pascal string. | |
28 syntax match webIgnoredStuff "@[@']" | |
29 | |
30 let b:current_syntax = "web" | |
31 | |
32 " vim: ts=8 |