0
0
mirror of https://github.com/vim/vim.git synced 2025-09-26 04:04:07 -04:00

runtime(vim): Update base-syntax file, improve class, enum and interface highlighting

- Enable folding of class, enum and interface declarations.
- Highlight constructor names with the Function highlight group, like
  other special methods.
- Mark function definitions using special method names as errors.
- Highlight :type arguments.

fixes: #14393#issuecomment-2042796198.
closes: #13810

Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
This commit is contained in:
Doug Kearns
2024-10-06 17:00:48 +02:00
committed by Christian Brabandt
parent ec0229414b
commit 818c641b6f
152 changed files with 1895 additions and 1018 deletions

View File

@@ -0,0 +1,36 @@
vim9script
# Vim :interface command
# VIM_TEST_SETUP let g:vimsyn_folding = 'i'
# VIM_TEST_SETUP setl fdc=2 fdl=99 fdm=syntax
interface Interface1
endinterface
export interface Interface2
endinterface
interface Interface2
# comment
var var1: number
endinterface
interface Interface3
# comment
def Meth1(): number
endinterface
interface Interface4
# comment
var var1: number
# comment
def Meth1(): number
endinterface
interface Interface5
# comment
var var1: number
var var2: number
# comment
def Meth1(): number
def Meth2(): number
endinterface