I want to make a snippet for a function with optional arguments. For example something like:
myfunc($1, $2, $3)
But in this case, $2 may be optional. I know I can press Ctrl-D to skip it, but it leaves behind the comma. How do I get a snippet to delete the comma if I skip the field?