Various minor adjustments to snippets

This commit is contained in:
2024-05-12 06:33:03 +02:00
parent def3c6b531
commit d42f1f53e8
5 changed files with 25 additions and 8 deletions

View File

@@ -38,8 +38,8 @@ for parameter in parameters:
paramless = parameter.replace("\t", "")
snip.rv += f"-- @variable {paramless}\n"
`-- @description $5
function ${1:Name}($2`!p if (t[2] == ""):
t[2] = "a, b: Integer"`) return ${3:Integer} is
function ${1:Name}${2:a, b: Integer}`!p if (t[2] != "" and not t[2].startswith("(")):
t[2] = f"({t[2]})"` return ${3:Integer} is
$4
begin
$7