Explorar el Código

added c snippets for else and if else and stuff

wreed4 hace 10 años
padre
commit
4ed3773360
Se han modificado 1 ficheros con 15 adiciones y 1 borrados
  1. 15 1
      UltiSnips/c.snippets

+ 15 - 1
UltiSnips/c.snippets

@@ -21,7 +21,21 @@ endsnippet
 snippet if "if (cond){ ... }"
 if (${1:cond}){
 	${2}
-}${0}
+} ${0}
+endsnippet
+
+snippet ife "if (cond){ ... } else { ... }"
+if (${1:cond}){
+	${2}
+} else {
+	${3}
+} ${0}
+endsnippet
+
+snippet el "else { ... }"
+else {
+	${3}
+} ${0}
 endsnippet