From d52b221bbc58afa7323f2c76d2f432f533b9f0d6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jes=C3=BAs=20Jos=C3=A9=20Maldonado=20Arroyo?= Date: Sat, 14 Dec 2024 16:51:33 +0100 Subject: [PATCH] Update plantuml.yaml-tmLanguage Modifies function and field regex to support lists in types when the type is specified after the variable name. Examples: - variable type[] - method() type[] --- syntaxes/plantuml.yaml-tmLanguage | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/syntaxes/plantuml.yaml-tmLanguage b/syntaxes/plantuml.yaml-tmLanguage index dd8d0e0..fcecd41 100644 --- a/syntaxes/plantuml.yaml-tmLanguage +++ b/syntaxes/plantuml.yaml-tmLanguage @@ -328,7 +328,7 @@ repository: '3': {name: string.quoted.double.class.group.separator.source.wsd} '4': {name: meta.comment.class.group.separator.source.wsd} - comment: function # https://rubular.com/r/9p7JpPGAJtcGFJ - match: (?i)^\s*(\s*\{(static|abstract)\}\s*)?(\s*[~#+-]\s*)?(([\p{L}0-9_]+(\[\])?\s+)?([\p{L}0-9_]+)(\(\))|([\p{L}0-9_]+)(\(\))\s*:\s*([\p{L}0-9_]+)?)\s*$ + match: (?i)^\s*(\s*\{(static|abstract)\}\s*)?(\s*[~#+-]\s*)?(([\p{L}0-9_]+(\[\])?\s+)?([\p{L}0-9_]+)(\(\))|([\p{L}0-9_]+)(\(\))\s*:\s*([\p{L}0-9_]+(\[\])?)?)\s*$ captures: '1': {name: storage.modifier.class.function.source.wsd} '3': {name: keyword.other.class.function.source.wsd} @@ -337,7 +337,7 @@ repository: '9': {name: support.variable.class.function.source.wsd} '11': {name: support.type.class.function.source.wsd} - comment: fields # https://rubular.com/r/cJ15lkb8dcSGvK - match: (?i)^\s*(\s*\{(static|abstract)\}\s*)?(\s*[~#+-]\s*)?(([\p{L}0-9_]+(\[\])?\s+)?([\p{L}0-9_]+)|([\p{L}0-9_]+)\s*:\s*(\w+)?)\s*$ + match: (?i)^\s*(\s*\{(static|abstract)\}\s*)?(\s*[~#+-]\s*)?(([\p{L}0-9_]+(\[\])?\s+)?([\p{L}0-9_]+)|([\p{L}0-9_]+)\s*:\s*(\w+(\[\])?)?)\s*$ captures: '1': {name: storage.modifier.class.fields.source.wsd} '3': {name: keyword.other.class.fields.source.wsd}