fix tab completion, works for both snippets and auto complete