re-design snippets hierarchy

This commit is contained in:
Zhang Chiyuan
2008-03-10 12:26:15 +00:00
parent b376b1f00b
commit 61210bf5fd
78 changed files with 94 additions and 36 deletions

View File

@@ -1,8 +0,0 @@
#name : eval { ... } if ($@) { ... }
# --
eval {
${1:# do something risky...}
};
if (\$@) {
${2:# handle failure...}
}

View File

@@ -1,5 +0,0 @@
#name : for (...) { ... }
# --
for (my \$${1:var} = 0; \$$1 < ${2:expression}; \$$1++) {
${3:# body...}
}

View File

@@ -1,5 +0,0 @@
#name : foreach ... { ... }
# --
foreach my \$${1:x} (@${2:array}) {
${3:# body...}
}

View File

@@ -1,5 +0,0 @@
#name : if (...) { ... }
# --
if ($1) {
$0
}

View File

@@ -1,7 +0,0 @@
#name : if (...) { ... } else { ... }
# --
if ($1) {
$2
} else {
$3
}

View File

@@ -1,9 +0,0 @@
#name : if, elsif, else ...
# --
if ($1) {
${2:# body...}
} elsif ($3) {
${4:# elsif...}
} else {
${5:# else...}
}

View File

@@ -1,5 +0,0 @@
#name : sub ... { ... }
# --
sub ${1:function_name} {
$0
}

View File

@@ -1,5 +0,0 @@
#name : unless (...) { ... }
# --
unless ($1) {
$0
}

View File

@@ -1,5 +0,0 @@
#name : while (...) { ... }
# --
while ($1) {
$0
}

View File

@@ -1,3 +0,0 @@
#name : ... foreach ...
# --
${1:expression} foreach @${2:array};

View File

@@ -1,3 +0,0 @@
#name : ... if ...
# --
${1:expression} if ${2:condition}

View File

@@ -1,3 +0,0 @@
#name : ... unless ...
# --
${1:expression} unless ${2:condition}

View File

@@ -1,3 +0,0 @@
#name : ... while ...
# --
${1:expression} while ${2:condition};