2011-06-20 13:40:28 -04:00
|
|
|
snippet #!
|
|
|
|
#!/usr/bin/env falcon
|
2012-05-19 21:05:21 -04:00
|
|
|
|
2011-06-20 13:40:28 -04:00
|
|
|
# Import
|
|
|
|
snippet imp
|
|
|
|
import ${1:module}
|
2012-05-19 21:05:21 -04:00
|
|
|
|
2011-06-20 13:40:28 -04:00
|
|
|
# Function
|
|
|
|
snippet fun
|
|
|
|
function ${2:function_name}(${3})
|
2013-06-20 17:33:44 -04:00
|
|
|
${4}
|
2011-06-20 13:40:28 -04:00
|
|
|
end
|
2012-05-19 21:05:21 -04:00
|
|
|
|
2011-06-20 13:40:28 -04:00
|
|
|
# Class
|
|
|
|
snippet class
|
|
|
|
class ${1:class_name}(${2:class_params})
|
|
|
|
${3:/* members/methods */}
|
|
|
|
end
|
2012-05-19 21:05:21 -04:00
|
|
|
|
2011-06-20 13:40:28 -04:00
|
|
|
# If
|
|
|
|
snippet if
|
|
|
|
if ${1:condition}
|
2013-06-20 17:33:44 -04:00
|
|
|
${2}
|
2011-06-20 13:40:28 -04:00
|
|
|
end
|
2012-05-19 21:05:21 -04:00
|
|
|
|
2011-06-20 13:40:28 -04:00
|
|
|
# If else
|
|
|
|
snippet ife
|
|
|
|
if ${1:condition}
|
2013-06-20 17:33:44 -04:00
|
|
|
${2}
|
2011-06-20 13:40:28 -04:00
|
|
|
else
|
|
|
|
${1}
|
|
|
|
end
|
2012-05-19 21:05:21 -04:00
|
|
|
|
2011-06-20 13:40:28 -04:00
|
|
|
# If else if
|
|
|
|
snippet elif
|
|
|
|
elif ${1:condition}
|
2013-06-20 17:33:44 -04:00
|
|
|
${2}
|
2012-05-19 21:05:21 -04:00
|
|
|
|
|
|
|
# Switch case
|
|
|
|
snippet switch
|
|
|
|
switch ${1:expression}
|
|
|
|
case ${2:item}
|
|
|
|
case ${3:item}
|
|
|
|
default
|
|
|
|
end
|
|
|
|
|
|
|
|
# Select
|
|
|
|
snippet select
|
|
|
|
select ${1:variable}
|
|
|
|
case ${2:TypeSpec}
|
|
|
|
case ${3:TypeSpec}
|
|
|
|
default
|
|
|
|
end
|
|
|
|
|
2011-06-20 13:40:28 -04:00
|
|
|
# For/in Loop
|
|
|
|
snippet forin
|
|
|
|
for ${1:element} in ${2:container}
|
2013-06-20 17:33:44 -04:00
|
|
|
${3}
|
2011-06-20 13:40:28 -04:00
|
|
|
end
|
2012-05-19 21:05:21 -04:00
|
|
|
|
2011-06-20 13:40:28 -04:00
|
|
|
# For/to Loop
|
|
|
|
snippet forto
|
|
|
|
for ${1:lowerbound} to ${2:upperbound}
|
2013-06-20 17:33:44 -04:00
|
|
|
${3}
|
2011-06-20 13:40:28 -04:00
|
|
|
end
|
2012-05-19 21:05:21 -04:00
|
|
|
|
2011-06-20 13:40:28 -04:00
|
|
|
# While Loop
|
|
|
|
snippet while
|
|
|
|
while ${1:conidition}
|
2013-06-20 17:33:44 -04:00
|
|
|
${2}
|
2011-06-20 13:40:28 -04:00
|
|
|
end
|