From 8f73e9736317bd5d7951757357075504ea402d27 Mon Sep 17 00:00:00 2001 From: Moon Flower Date: Mon, 25 Aug 2025 16:53:34 +0330 Subject: cool stuff, right? multi-process support with permission levels --- pu2/i2-syntax/syntaxes/i2.tmLanguage.json | 26 +++++++++++++++++++++++++- 1 file changed, 25 insertions(+), 1 deletion(-) (limited to 'pu2/i2-syntax') diff --git a/pu2/i2-syntax/syntaxes/i2.tmLanguage.json b/pu2/i2-syntax/syntaxes/i2.tmLanguage.json index b1078e2..190711e 100644 --- a/pu2/i2-syntax/syntaxes/i2.tmLanguage.json +++ b/pu2/i2-syntax/syntaxes/i2.tmLanguage.json @@ -11,6 +11,9 @@ { "include": "#block-comments" }, + { + "include": "#imports" + }, { "include": "#macro-reference" }, @@ -132,6 +135,27 @@ } ] }, + "imports": { + "begin": "\\b(import)\\b\\s+", + "beginCaptures": { + "1": { + "name": "keyword.control.import.i2" + } + }, + "end": ";", + "endCaptures": { + "0": { + "name": "punctuation.separator.semicolon.i2" + } + }, + "name": "meta.import.i2", + "patterns": [ + { + "name": "constant.other.path.i2", + "match": "(?:\\./|/)?[A-Za-z0-9_./-]+\\.i2\\b" + } + ] + }, "braces": { "name": "punctuation.section.block.i2", "match": "[\\{\\}]" @@ -146,7 +170,7 @@ }, "keywords": { "name": "keyword.control.i2", - "match": "\\b(?:macro|system|exit|let|while|if)\\b" + "match": "\\b(?:macro|system|exit|let|while|if|import)\\b" }, "jump-call": { "begin": "\\b(?:jmp|jz|jnz)\\s*\\(", -- cgit v1.2.3