Remove "identifier.class" rule to reduce complexities

This commit is contained in:
2025-06-15 14:06:04 -04:00
parent 6e8f69839f
commit f61d32e75f
3 changed files with 4 additions and 4 deletions
+1 -1
View File
@@ -6,7 +6,7 @@ func init() {
syntaxMap["csharp"] = &lazySyntax{init: func() []byte { syntaxMap["csharp"] = &lazySyntax{init: func() []byte {
return []byte(`filetype: csharp return []byte(`filetype: csharp
rules: rules:
- identifier.class: "class +[A-Za-z0-9]+ *((:) +[A-Za-z0-9.]+)?" - identifier.macro: "class +[A-Za-z0-9]+ *((:) +[A-Za-z0-9.]+)?"
- identifier.var: "@[A-Za-z]+" - identifier.var: "@[A-Za-z]+"
- identifier: "[A-Za-z_][A-Za-z0-9_]*[[:space:]]*[()]" - identifier: "[A-Za-z_][A-Za-z0-9_]*[[:space:]]*[()]"
- type: "\\b(bool|byte|sbyte|char|decimal|double|float|IntPtr|int|uint|long|ulong|object|short|ushort|string|base|this|var|void)\\b" - type: "\\b(bool|byte|sbyte|char|decimal|double|float|IntPtr|int|uint|long|ulong|object|short|ushort|string|base|this|var|void)\\b"
+1 -1
View File
@@ -15,7 +15,7 @@ rules:
- symbol: "\\.|\\$" - symbol: "\\.|\\$"
- constant.bool: "\\b(True|False)\\b" - constant.bool: "\\b(True|False)\\b"
- constant: "(Nothing|Just|Left|Right|LT|EQ|GT)" - constant: "(Nothing|Just|Left|Right|LT|EQ|GT)"
- identifier.class: "[ ](Read|Show|Enum|Eq|Ord|Data|Bounded|Typeable|Num|Real|Fractional|Integral|RealFrac|Floating|RealFloat|Monad|MonadPlus|Functor)" - identifier: "[ ](Read|Show|Enum|Eq|Ord|Data|Bounded|Typeable|Num|Real|Fractional|Integral|RealFrac|Floating|RealFloat|Monad|MonadPlus|Functor)"
- constant.string: - constant.string:
start: "\"" start: "\""
end: "\"" end: "\""
+2 -2
View File
@@ -19,9 +19,9 @@ rules:
- constant.string.url: "(ftp(s)?|http(s)?|git|chrome)://[^ ]+" - constant.string.url: "(ftp(s)?|http(s)?|git|chrome)://[^ ]+"
- comment: "<!--.+?-->" - comment: "<!--.+?-->"
- default: "<\\?(php|=)\" end=\"\\?>" - default: "<\\?(php|=)\" end=\"\\?>"
- identifier.class: "([a-zA-Z0-9_-]+)\\(" - identifier.macro: "([a-zA-Z0-9_-]+)\\("
- preproc: "^\\s*(require|include|require_once|include_once)" - preproc: "^\\s*(require|include|require_once|include_once)"
- identifier.class: "[a-zA-Z\\\\]+::" - identifier.macro: "[a-zA-Z\\\\]+::"
- identifier: "([A-Z][a-zA-Z0-9_]+)\\s" - identifier: "([A-Z][a-zA-Z0-9_]+)\\s"
- identifier: "([A-Z0-9_]+)[;|\\s|\\)|,]" - identifier: "([A-Z0-9_]+)[;|\\s|\\)|,]"
- keyword: "(global|public|private|protected|static|const)" - keyword: "(global|public|private|protected|static|const)"