GNOME Bugzilla – Bug 424585
PHP function snippet does not work correctly
Last modified: 2019-03-23 20:47:24 UTC
Bug reported on Ubuntu (http://launchpad.net/bugs/89587): In gedit 2.16.1, using the php function snippet, by writing function<tab> on a php file changes to this: public function FunctionName (${3: $value${5:=''} }) { # code... } I've managed to fix the ${5 part by adding a space after value, however, I have not found a way to fix the $3 part. As I couldn't find another nested snippet, I can't test if this is a typo or a feature not yet implemented.
Thanks for reporting this bug! Nested snippets are indeed not supported and this is probably a left over from automatically copying over TextMate snippets. I've been over the php snippets and fixed them to work properly. We might think about supporting this kind of nesting, but it would require some thinking in how to implement this. Another problem I encountered in the php snippets is placeholders which are directly after each other ($1$2), this is also not supported because there is a problem in deciding in which placeholder the cursor currently is (this can be fixed I think, but again requires some careful thinking).