runtime(python): Update syntax, fix pythonEllipsis pattern

Commit: 
https://github.com/vim/vim/commit/15070eee2f1e11a69a4c2d99bad03c8f6756e6e0
Author: Doug Kearns <[email protected]>
Date:   Thu Sep 11 13:54:51 2025 -0400

    runtime(python): Update syntax, fix pythonEllipsis pattern
    
    fixes: https://github.com/vim/vim/issues/18263
    closes: https://github.com/vim/vim/issues/18264
    
    Signed-off-by: Doug Kearns <[email protected]>
    Signed-off-by: Christian Brabandt <[email protected]>

diff --git a/runtime/syntax/python.vim b/runtime/syntax/python.vim
index 542805d84..86aa6d329 100644
--- a/runtime/syntax/python.vim
+++ b/runtime/syntax/python.vim
@@ -314,7 +314,7 @@ if !exists("python_no_builtin_highlight")
        \ 
contains=ALLBUT,pythonBuiltin,pythonClass,pythonFunction,pythonType,pythonAsync
        \ transparent
   " the ellipsis literal `...` can be used in multiple syntactic contexts
-  syn match   pythonEllipsis   "\.\@1<!.\.\.\ze\.\@!" display
+  syn match   pythonEllipsis   "\.\@1<!\.\.\.\ze\.\@!" display
 endif
 
 " From the 'Python Library Reference' class hierarchy at the bottom.
diff --git a/runtime/syntax/testdir/dumps/python_ellipsis_01.dump 
b/runtime/syntax/testdir/dumps/python_ellipsis_01.dump
index f1495fd33..03a7de81c 100644
--- a/runtime/syntax/testdir/dumps/python_ellipsis_01.dump
+++ b/runtime/syntax/testdir/dumps/python_ellipsis_01.dump
@@ -17,4 +17,4 @@
 |[+0#e000e06&|0|,| |1|,| |.+0#00e0e07&@2|,+0#e000e06&| |1|8|,| |1|9|]| 
+0#0000000&@55
 |>+0#e000e06&@2| |e+0#00e0e07&|x|e|c|(+0#0000000&|s|)| 
+0#e000e06&@1|#+0#0000e05&|d|o|c|t|e|s|t|:| |+|E|L@1|I|P|S|I|S| +0#0000000&@42
 |-+0#e000e06&|3|.|2|1|7|1|6|0|3|4|2|7|2|e|-|0|.+0#00e0e07&@2|7+0#e000e06&| 
+0#0000000&@53
-@57|1|9|,|1| @9|5|4|%| 
+@57|1|9|,|1| @9|4|8|%| 
diff --git a/runtime/syntax/testdir/dumps/python_ellipsis_02.dump 
b/runtime/syntax/testdir/dumps/python_ellipsis_02.dump
index 7a7417a77..8c97c30b4 100644
--- a/runtime/syntax/testdir/dumps/python_ellipsis_02.dump
+++ b/runtime/syntax/testdir/dumps/python_ellipsis_02.dump
@@ -10,11 +10,11 @@
 @75
 |#+0#0000e05&| |N|u|m|p|y| +0#0000000&@67
 |x|[|.+0#00e0e07&@2|,+0#0000000&| |0+0#e000002&|]+0#0000000&| @65
+@75
+|#+0#0000e05&| |I|s@1|u|e| |#|1|8|2|6|3| |(|P|y|t|h|o|n| 
|h|i|g|h|l|i|g|h|t|i|n|g| |e|l@1|i|p|s|i|s|,| |f|a|l|s|e| |p|o|s|i|t|i|v|e|)| 
+0#0000000&@13
+|a| |=| |"+0#e000002&|.@1|"| +0#0000000&|#+0#0000e05&| |c|o|m@1|e|n|t| 
+0#0000000&@56
 |~+0#4040ff13&| @73
 |~| @73
 |~| @73
 |~| @73
-|~| @73
-|~| @73
-|~| @73
 | +0#0000000&@56|3|7|,|2|-|9| @7|B|o|t| 
diff --git a/runtime/syntax/testdir/input/python_ellipsis.py 
b/runtime/syntax/testdir/input/python_ellipsis.py
index 525328305..ac8ecc393 100644
--- a/runtime/syntax/testdir/input/python_ellipsis.py
+++ b/runtime/syntax/testdir/input/python_ellipsis.py
@@ -41,3 +41,6 @@ class C:
 
 # Numpy
 x[..., 0]
+
+# Issue #18263 (Python highlighting ellipsis, false positive)
+a = ".." # comment

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion visit 
https://groups.google.com/d/msgid/vim_dev/E1uwlaZ-000RBX-L8%40256bit.org.

Raspunde prin e-mail lui