From 715e4865e130256d335e0856d598fddc04fbe9be Mon Sep 17 00:00:00 2001 From: emekoi Date: Wed, 16 Oct 2019 21:01:52 -0500 Subject: [PATCH] fixed return type highlighting with generic parameters --- Syntaxes/Zig.YAML-tmLanguage | 2 +- Syntaxes/Zig.tmLanguage | 2 +- Syntaxes/Zig.tmLanguage.json | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Syntaxes/Zig.YAML-tmLanguage b/Syntaxes/Zig.YAML-tmLanguage index f55147b..dab69ef 100644 --- a/Syntaxes/Zig.YAML-tmLanguage +++ b/Syntaxes/Zig.YAML-tmLanguage @@ -291,7 +291,7 @@ repository: '2': name: punctuation.section.parens.begin.zig - end: '(?<=\))\s*([a-zA-Z_][a-zA-Z0-9_.]*|@\".+\")?(!)?\s*(?:([a-zA-Z_][a-zA-Z0-9_.]*|@\".+\")\b(?!\s*\())?' + end: '(?<=\)[^\)])\s*([a-zA-Z_][a-zA-Z0-9_.]*|@\".+\")?(!)?\s*(?:([a-zA-Z_][a-zA-Z0-9_.]*|@\".+\")\b(?!\s*\())?' endCaptures: '1': name: storage.type.zig diff --git a/Syntaxes/Zig.tmLanguage b/Syntaxes/Zig.tmLanguage index 8555bf7..7a79ade 100644 --- a/Syntaxes/Zig.tmLanguage +++ b/Syntaxes/Zig.tmLanguage @@ -313,7 +313,7 @@ end - (?<=\))\s*([a-zA-Z_][a-zA-Z0-9_.]*|@\".+\")?(!)?\s*(?:([a-zA-Z_][a-zA-Z0-9_.]*|@\".+\")\b(?!\s*\())? + (?<=\)[^\)])\s*([a-zA-Z_][a-zA-Z0-9_.]*|@\".+\")?(!)?\s*(?:([a-zA-Z_][a-zA-Z0-9_.]*|@\".+\")\b(?!\s*\())? endCaptures 1 diff --git a/Syntaxes/Zig.tmLanguage.json b/Syntaxes/Zig.tmLanguage.json index 1df7197..2ae7a8e 100644 --- a/Syntaxes/Zig.tmLanguage.json +++ b/Syntaxes/Zig.tmLanguage.json @@ -469,7 +469,7 @@ ] }, "function_def": { - "end": "(?<=\\))\\s*([a-zA-Z_][a-zA-Z0-9_.]*|@\\\".+\\\")?(!)?\\s*(?:([a-zA-Z_][a-zA-Z0-9_.]*|@\\\".+\\\")\\b(?!\\s*\\())?", + "end": "(?<=\\)[^\\)])\\s*([a-zA-Z_][a-zA-Z0-9_.]*|@\\\".+\\\")?(!)?\\s*(?:([a-zA-Z_][a-zA-Z0-9_.]*|@\\\".+\\\")\\b(?!\\s*\\())?", "begin": "(?<=fn)\\s+([a-zA-Z_][a-zA-Z0-9_]*|@\\\".+\\\")(\\()", "beginCaptures": { "1": {